manifest¶
The manifests of the task types: a task type as data, simrun.task-type/1.
A manifest declares what a TaskType declares, as JSON: the JSON Schema of its
settings, its ports, its resource hint, its flags and its implementations. The
Rust implementation of simrun (crates/simrun-core) reads task types as
manifests; this module writes the manifest of a python task type, so that the
task types of the python plugins are manifests as well (python -m
simrun.manifest), and answers the environment of the plugins (python -m
simrun.manifest --environment), which a local service records. A python task type has the implementation
python, its functions as module:function references (the count of its units
by a setting {"setting": <name>} for a type with units_setting), a type with a
command the implementation command with that argv as its run, and a type
with a native entry the implementation native of the Rust harness first.
See docs/superpowers/specs/2026-11-29-rust-wasm-design.md for the format.
manifest_of
¶
The manifest of a task type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
task_type
|
TaskType
|
The task type. |
required |
Returns:
| Type | Description |
|---|---|
dict[str, Any]
|
The manifest as JSON data. |
environment
¶
The environment of the python plugins, as a local service records it.
Returns:
| Type | Description |
|---|---|
dict[str, str]
|
|
dict[str, str]
|
entry points of the task types with the names and versions of their |
dict[str, str]
|
distributions, so a new, removed or upgraded plugin changes it. The plugins |
dict[str, str]
|
are not imported. |
write_manifests
¶
Write the manifest of every task type, <out>/<name>.json.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
out
|
Path
|
The directory. |
required |
types
|
dict[str, TaskType]
|
The task types by name. |
required |
Returns:
| Type | Description |
|---|---|
list[Path]
|
The files written. |
main
¶
Write the manifests of the installed task types, or print them as JSON.
With --environment it prints environment() instead.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
argv
|
list[str] | None
|
The arguments, those of the command line without. |
None
|