Built-in sandbox SHIM: a toml-compatible module for the model's Python
sandbox — NO host/JVM bridge. The toml PyPI package is not in GraalPy, so
agents that reach for import toml would otherwise hit ModuleNotFoundError;
this extension contributes a :ext/sandbox-shims entry that env-python
installs into every sandbox Context (main + every sub_loop fork).
Reading (toml.loads/toml.load) delegates to the stdlib tomllib (present
in GraalPy's 3.11 stdlib) for a spec-correct parse; writing
(toml.dumps/toml.dump) is a pure-Python serializer covering scalars,
arrays, inline tables, nested [table] sections and [[array.of.tables]].
A correctness-focused SUBSET of the toml package API.
Like shim-numpy there are NO :shim/bindings: a self-contained Python
preamble with zero host callables. Publishes a toml module into
sys.modules (so import toml works) and staples it onto builtins.
Built-in sandbox SHIM: a `toml`-compatible module for the model's Python sandbox — NO host/JVM bridge. The `toml` PyPI package is not in GraalPy, so agents that reach for `import toml` would otherwise hit ModuleNotFoundError; this extension contributes a `:ext/sandbox-shims` entry that env-python installs into every sandbox Context (main + every `sub_loop` fork). Reading (`toml.loads`/`toml.load`) delegates to the stdlib `tomllib` (present in GraalPy's 3.11 stdlib) for a spec-correct parse; writing (`toml.dumps`/`toml.dump`) is a pure-Python serializer covering scalars, arrays, inline tables, nested `[table]` sections and `[[array.of.tables]]`. A correctness-focused SUBSET of the `toml` package API. Like `shim-numpy` there are NO `:shim/bindings`: a self-contained Python preamble with zero host callables. Publishes a `toml` module into `sys.modules` (so `import toml` works) and staples it onto builtins.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |