Repository navigation
docs: document [sessions.<name>] entries and [box_types.<name>] types - #4033
Conversation
An entry whose type is a `[box_types]` type could not start: `min box start` refused it as an unsupported type, and `min session start` refused it as an entry whose session root the client cannot tell. So a type's `defaults.network` (BOX-233) reached `min box spec <entry>` but no box. `mfile::entry::read_entries` now resolves each entry's built-in root through the file's `[box_types]` (BOX-059) and keeps it on `BoxEntry`. The start picks and plans by that root, as the architecture's type nouns narrow by root: a session-rooted entry starts through `min box start` and `min session start` on the session path, and counts as a session entry for a bare start and for the egress pick (closes the #3140 refusal for a type that resolves). A task-rooted `[boxes]` entry reaches the #3213 refusal, which now names its type. Any other root, an unresolved type and a missing type are refused with exit 2, naming the roots that start. Spec 28 gains BCLI-089. The CLI and minimal.toml references say which entries start. The session e2e gains `project_box_type_network` (N176). Refs #3990, #3140, #3197, #3213. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…x type error, exit 3 Arch condition C1 on #3998: a type that does not resolve (a cycle, an unknown `extends`, an undeclared type) and a missing `type` are invalid configuration, exit 3 (architecture.md Box Types and exit codes). - `mfile::box_types::EntryRoots` reads each `[box_types.<name>]` on its own, so a broken type fails only the entries whose chain reaches it. A valid type beside it keeps its root. `BoxEntry::type_error` keeps the reason. - The start refuses an entry with no root with that `BoxTypeError` as `ProjectFileInvalid` (exit 3), for a typed entry and when the pick must count the entries. `SessionEntryUndecided::TypeUnresolved` is gone. `UnsupportedType` (exit 2) is left for the agent, service, build and container-build roots only. - Spec 28 BCLI-089 gains the exit-3 sub-bullet. The CLI and minimal.toml references say exit 3, and drop the obsolete row that refused a named session entry other than `default`. - The e2e case checks that the box runs a command and has curl before it probes, fails on any probe failure but a resolve failure or a timeout, and reports an unverified enforcement as incomplete, not OK. Refs #3990, #3998. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…caped The start of an entry whose type does not resolve now refuses with the BoxTypeError itself. Its names come from minimal.toml, so a control character in one is printed as its escape and cannot rewrite the refusal. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
… broken Arch clarified C1 on #3998 (architecture.md line 1502): a `[box_types]` with a broken type is invalid as a whole. Every entry of a type that is not built in, a valid type's entry included, is refused with the file's first `BoxTypeError` and exit 3, as `BoxTypes::from_file` refuses them in the loadout gate and the type layers. An entry of a built-in type still starts. `EntryRoots` now wraps `BoxTypes::from_file`. The start test refuses `web` beside a broken `loop` with the `loop` error for both verbs, and starts the built-in session and task entries beside it. Spec 28 BCLI-089, the CLI reference and the minimal.toml reference say the same. Refs #3990, #3998. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
The type error escaped only control characters, so a bidi override or a zero-width character in a type name still printed raw. The rule min box audit uses for the same threat moves to boxes::terminal, and both use it. The docs say a built-in entry still starts when the start names it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
Co-Authored-By: C 8000 laude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
An entry of a project Box Type that extends task could not run: min box start reached the #3213 refusal and min task run said "unknown task", because only [tasks] held tasks. [tasks.<name>] is sugar for type = "task" (BOX-046), so such an entry lives in [boxes]. mfile now reads each [boxes.<name>] entry whose type's built-in root is task as a task, beside File::tasks, so the client, mctx and the box host all find it. A task entry with no action, as min init --type task writes it, leaves the file loading; its run refuses it with exit 3. The run and the start look the entry up by root, so the box takes the type's defaults.network (BOX-233). A broken [box_types] refuses the run with its first error, exit 3. The #3213 refusal is gone. Spec 28 gains BCLI-090. Docs and an e2e case follow. Closes #3996. Closes #3213. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
A box started from an entry of a project Box Type now records that type (`netsess`, `ci`) in its record and its stored spec, with the built-in root in the spec's `type.root` (BOX-001, BOX-059, BOX-071). The daemon stamps the record's type from the received spec, else the creating verb's type, and reports each listed box's root. Per the owner ruling of 2026-12-03 (#3997), the type nouns cover the types built on them: `min session list|attach|logs| stop|rm` and `min task list|logs|stop|rm` match a box by its type or its built-in root. Spec 29 BOX-001 and spec 28 BCLI-030/032 are amended. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…s packages Review of #4005: - The refusal of a network key that a task box does not apply now reads the layers the entry expands from: its own table, [defaults.<type>] and each project type's defaults in its chain. [defaults.task] is no layer of a ci entry. [defaults] stays out, as #3671 tracks. - A task-rooted type's defaults.packages reach the box: the lists sent with the entry come from an expansion with the type chain's layers. - A [boxes.default] task entry with no action is refused as a task, exit 3, not as the implicit session's terminal, exit 2. - cli-min.md says which network keys a task box applies, and that the others refuse the run. BCLI-090 gains sub-bullets for both. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…e' into fix/3997-record-project-box-type
…e root Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…tored spec Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…ne preview Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…sk type's loadouts Review of #4005, round 2: - [defaults] is a layer of every entry (architecture.md line 1408), so the refusal of a network key that a task box does not apply now reads it too, for every task entry. A session-only key belongs in [defaults.session]. An ingress that a more specific mode = "none" clears is not refused (gominimal/arch#188). - task_loadout_mode finds the task entry by its root, not its type's name, so a ci entry takes the loadout_mode of its own table and of its type's defaults instead of the sealed task default. - BCLI-090 and the CLI and minimal.toml references say so. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…e' into fix/3997-record-project-box-type
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
… type Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…b's type Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
Review of #4005, round 3: - The refusal of a network key that a task box does not apply takes the run's --network flag. --network none clears the ingress of every layer (BCLI-024), so that ingress no longer refuses the run. The test puts the [defaults] ingress back and checks the run passes without it. - A run of an entry whose type does not resolve checks the type before the terminal, so [boxes.default] of such a type exits 3, not 2. - BCLI-090's refusal gains the ingress exception, verified for the mode = "none" layer and the flag. A stale test comment is fixed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…spec min box spec picked the task path by the entry's type name, so a ci entry, which extends task, rendered on the session path: a network its run never gives the box, no refusal of an unapplied key, and --ingress accepted. It now picks the path by the entry's built-in root, as the run and the start do, and so does the check for a credentialed grant. box_entry sends env_vars and patches only for a non-task root, so a ci entry is treated as a [tasks] entry there too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…e' into fix/3997-record-project-box-type
min box spec of a task-rooted entry kept the egress and ingress its layers set beside mode none, where min task run --network none clears them. The spec's task path now clears them the same way. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…e' into fix/3997-record-project-box-type
…at another verb's type Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
A task box takes its env_vars and patches from its own entry table, which the box host reads when the task runs. The expansion is not sent for a task-rooted entry, since the host would then apply the entry's own values twice. So a ci type's defaults.env_vars or patches were dropped in silence. The run, the start and min box spec now refuse them with exit 3, naming the table and the entry to set them in. [defaults] and [defaults.task] stay the gap of #3266. The box_entry comments, cli-min.md and BCLI-090 say so. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTvep9ZaSf5pJMB2hQA
…e' into fix/3997-record-project-box-type
- minimal-dot-toml.md gains a [sessions.<name>] section beside [tasks.*], with an example and the keys a session applies, and a [box_types.<name>] section: extends, defaults, constraints, description, how an entry names a type, and what each root starts with. - A short guide, docs/guide/box-types.md, walks through defining a type and running an entry of it. - cli-min.md's box spec section says a spec is rendered from minimal.toml each time and not saved. - min type list prints on stderr how to define a type when the project has none. Fixes #4020 Fixes #4022 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
There was a problem hiding this comment.
minimal-review — approval withheld
Verdict COMMENT — APPROVE withheld: 9 unresolved threads — minimal-arch[bot] docs/reference/minimal-dot-toml.md:362, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, …. No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
There was a problem hiding this comment.
Review of the docs against the code at 5b54fef. Most of the new reference holds up. The [sessions.<name>] key table matches box_entry, KEPT_EXPANDED_SECTIONS, ends_with_entrypoint and timeout_of. hooks_on_resume matches box_actor.rs, [defaults.<type>] matches with_file_defaults, and [sessions]/[tasks] reject a different type in entry_type. The [box_types] keys, the built-in roots, the #4031 and #3197 limits and the anchors are correct too. One substantive problem remains, in both the guide and the reference: they say a type's constraints are enforced on entries, with exit 3 naming the admitted values. At this head only loadout_mode is enforced. check_constraints has no product caller, and #3295, which adds that call, is still open. So the guide's motivating example ("must never get a host-address network") is not a guarantee today. The min type list hint's stderr and -o gating also lacks a test. Two lows are inline. The earlier arch-review and minimal-review threads look addressed.
Generated by Claude Code
…the type list hint's streams Norrie's review of #4033. This release checks a project type's constraints against an entry only for loadout_mode (check_constraints has no product caller, #3295), so the guide and the reference say so, and the example constrains loadout_mode instead of a network mode. The reference lists every type load error, with no count. cmd_type_list_in takes a stderr writer, and a test pins that the hint is on stderr alone, and absent with -o or with a project type. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
|
/arch-review |
There was a problem hiding this comment.
arch-review: PASS · the full ruling
The compare corrects the docs. They now say that this release checks only a loadout_mode constraint against an entry, and they link #3295 for the other keys. The code agrees: loadout_gate refuses on the min task run path, and check_constraints has no product caller yet. The Box Types section requires constraint enforcement, and the docs now state that gap honestly with its issue. The min type list hint change only moves the stderr write behind a writer, and a test pins it. No condition is open.
Ruled at 86148d4 against gominimal/arch@5cfb8febb353 by claude-opus-5-5.
There was a problem hiding this comment.
minimal-review — approval withheld
Verdict COMMENT — APPROVE withheld: 14 unresolved threads — minimal-arch[bot] docs/reference/minimal-dot-toml.md:362, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, …. No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
Karl's rule for the user docs: state true facts about how the software works, with no 'not yet' or issue-number copy, and no mention of keys with no implementation. The session table lists exec_enabled, which the release applies (#4037). The paragraph of accepted-but-unapplied keys goes. Constraints are documented as the loadout_mode limit they are, and the task-root env_vars/patches rule and the roots that do not start are stated as plain facts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
|
/arch-review |
Karl's rule: session and task are the Box Types users have. The built-in list names those two, extends names session, task or another type of the project, and the line about roots that do not start goes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
|
/arch-review |
There was a problem hiding this comment.
arch-review: CONDITIONS · 3 conditions · the full ruling
Three new statements in the docs do not match the code at this head. The session table lists exec_enabled as applied, but the carry is in #4037, which this branch does not contain (C1, architecture.md line 529). The reference names two built-in types, but the code and min type list have six (C2, lines 35 and 492). The task-root text describes a silent drop, but the code refuses with exit code 3 (C3, line 376). The rest of the change keeps its earlier PASS.
Ruled at 64e217c against gominimal/arch@5cfb8febb353 by claude-opus-5-5.
| | `timeout` | How long the box runs before Minimal ends it. See [`timeout`](#timeout). It applies only with `lifetime = "until_complete"` | | ||
| | `network` | The box's network mode and its egress and ingress rules. See [`[defaults]`](#defaults) | | ||
| | `secrets` | Variables whose sealed values come from the credential broker or your secret store. See [`min secret`](./cli-min.md#secret-set-secret-list-and-secret-rm) | | ||
| | `exec_enabled` | `false` stops `min box exec` from running a command in the box. It can also go under `[io]` | |
There was a problem hiding this comment.
|
|
||
| ### `[box_types.<name>]` - Define your own box types {#box-types} | ||
|
|
||
| A Box Type is a kind of box. Every entry of the type gets its settings. The built-in types are `session` and `task`. A project defines its own types in |
There was a problem hiding this comment.
C2 · BUILTIN_BOX_TYPES has six types, and min type list prints six built-in rows. Name all six here (architecture.md lines 35 and 492). In the list of roots, say that an entry with any other root does not start.
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): session and task are the only Box Types users have, and the user docs name no other built-in type, not even in a refusal sentence. The code's other built-in types are not part of the user-facing product.
|
|
||
| | Key | What it does | | ||
| |---|---| | ||
| | `extends` | Names the type this type builds on: `session`, `task`, or another type of the project. Required | |
There was a problem hiding this comment.
C2 · A project type can extend any of the six built-in types, and it loads. Write: a built-in type or another type of the project (architecture.md line 1553).
There was a problem hiding this comment.
Disputed, on the same ruling: the docs name session and task as the built-in types a project type extends, plus another type of the project. They don't list the other built-in types.
| - A type whose root is `session` starts with `min session start <entry>` or | ||
| `min box start <entry>`. | ||
| - A type whose root is `task` runs with `min task run <entry>` or | ||
| `min box start <entry>`. Its entries take `env_vars` and `patches` from the |
There was a problem hiding this comment.
C3 · The code refuses this with exit code 3 (TaskNetworkUnapplied). It does not drop the values. Say that min task run and min box start refuse a task-root type that sets env_vars or patches in defaults or [defaults.<type>].
There was a problem hiding this comment.
Addressed in 1ed4ac6: the reference now says to set env_vars and patches on the entry, and that a type whose defaults or [defaults.<type>] sets either key fails to run with exit code 3, the error naming the key and the table (refuse_task_type_env).
| | `session` | `min session start <entry>` or `min box start <entry>` | | ||
| | `task` | `min task run <entry>` or `min box start <entry>` | | ||
|
|
||
| An entry of a type whose root is `task` takes `env_vars` and `patches` from |
There was a problem hiding this comment.
C3 · Same as the reference: the run is refused with exit code 3. The values are not dropped. State the refusal and its exit code.
There was a problem hiding this comment.
Addressed in 1ed4ac6: the guide states the refusal: min task run refuses the entry with exit code 3 and names the key and the table.
… refused with exit 3 arch-review C3: the code refuses such a type (refuse_task_type_env), with exit 3 naming the key and the table. It does not drop the values. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
|
/arch-review |
There was a problem hiding this comment.
minimal-review — approval withheld
Verdict COMMENT — APPROVE withheld: 19 unresolved threads — minimal-arch[bot] docs/reference/minimal-dot-toml.md:363, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, …. No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
There was a problem hiding this comment.
arch-review: CONDITIONS · 2 conditions · the full ruling
The new task-root sentence is correct, and C3 is met. refuse_task_type_env refuses with exit code 3 for min task run and min box start, and it names the key and the table. C1 and C2 are still open. Line 358 documents exec_enabled, but #4037 is not an ancestor of this branch. Line 475 names two built-in types, and the design names six (architecture.md line 35). Make the edits in C1 and C2.
Ruled at 1ed4ac6 against gominimal/arch@5cfb8febb353 by claude-opus-5-5.
| | `timeout` | How long the box runs before Minimal ends it. See [`timeout`](#timeout). It applies only with `lifetime = "until_complete"` | | ||
| | `network` | The box's network mode and its egress and ingress rules. See [`[defaults]`](#defaults) | | ||
| | `secrets` | Variables whose sealed values come from the credential broker or your secret store. See [`min secret`](./cli-min.md#secret-set-secret-list-and-secret-rm) | | ||
| | `exec_enabled` | `false` stops `min box exec` from running a command in the box. It can also go under `[io]` | |
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): the user docs document what this release ships as working. #4037, which applies exec_enabled, is in the release candidate and merges before this PR (see the PR body), so the row is true on main when the docs land. Karl's approval gates the order.
|
|
||
| ### `[box_types.<name>]` - Define your own box types {#box-types} | ||
|
|
||
| A Box Type is a kind of box. Every entry of the type gets its settings. The built-in types are `session` and `task`. A project defines its own types in |
There was a problem hiding this comment.
C2 · The design names six built-in types (architecture.md line 35). Name session, task, agent, service, build and container-build, as BUILTIN_BOX_TYPES does. Also fix the extends row at line 500, and add the refusal sentence for the other roots after line 529.
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): session and task are the only Box Types users have. The user docs name no other built-in type, including in an extends row or a refusal sentence. architecture.md's six-type list is the design's inventory, not the user-facing set.
There was a problem hiding this comment.
minimal-review — approval withheld
Verdict COMMENT — APPROVE withheld: 21 unresolved threads — minimal-arch[bot] docs/reference/minimal-dot-toml.md:363, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, …. No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
Rebuilt on main after #4005 and #4008 squash-merged: this PR's own change over its old stack base, applied unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
|
/arch-review |
There was a problem hiding this comment.
arch-review: CONDITIONS · 1 condition · the full ruling
C1 is met: #4037 is now in this branch, so the exec_enabled row is true. C2 is still open. The PR's text in minimal-dot-toml.md did not change in this push. Line 561 names two built-in types, but the design ships six and min type list prints six. Name all six at line 561. At line 586, let extends name any built-in type. At lines 612-617, say that min box start refuses an entry with any other built-in root.
Ruled at b362204 against gominimal/arch@5cfb8febb353 by claude-opus-5-5.
|
|
||
| ### `[box_types.<name>]` - Define your own box types {#box-types} | ||
|
|
||
| A Box Type is a kind of box. Every entry of the type gets its settings. The built-in types are `session` and `task`. A project defines its own types in |
There was a problem hiding this comment.
C2 · This line names two built-in types. The design (Glossary, line 35) ships six, and min type list prints six. Name session, task, agent, service, build and container-build here.
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): session and task are the only Box Types users have, and the user docs name no other built-in type, including in extends or a refusal sentence. Karl approved this PR with that text.
|
|
||
| | Key | What it does | | ||
| |---|---| | ||
| | `extends` | Names the type this type builds on: `session`, `task`, or another type of the project. Required | |
There was a problem hiding this comment.
C2 · extends can name any of the six built-in types, or another type of the project (Composition, line 1553). Write that here.
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): session and task are the only Box Types users have, and the user docs name no other built-in type, including in extends or a refusal sentence. Karl approved this PR with that text.
| - A type whose root is `task` runs with `min task run <entry>` or | ||
| `min box start <entry>`. Set its `env_vars` and `patches` on the entry. A | ||
| type whose `defaults`, or whose `[defaults.<type>]`, sets either key fails | ||
| to run with exit code 3, and the error names the key and the table. |
There was a problem hiding this comment.
C2 · After this item, add one sentence. An entry whose type has any other built-in root does not start, and min box start refuses it.
There was a problem hiding this comment.
Disputed, on Karl's ruling (2026-12-04): session and task are the only Box Types users have, and the user docs name no other built-in type, including in extends or a refusal sentence. Karl approved this PR with that text.
There was a problem hiding this comment.
minimal-review — approval withheld
Verdict COMMENT — APPROVE withheld: 21 unresolved threads — minimal-arch[bot] docs/reference/minimal-dot-toml.md:364, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/guide/box-types.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, minimal-arch[bot] docs/reference/minimal-dot-toml.md, …. No findings.
Panel: 3 of 3 personas ran (correctness, security, supply-chain).
There was a problem hiding this comment.
Re-review at b362204, judged on the PR's own diff against main. The docs now match the code at this head. They say that loadout_mode is the only constraint checked against an entry. entry_loadout_gate refuses it on the create and min box spec paths, and the example type constrains only that key. The session key table lists exec_enabled as applied. That is true now, because #4037 is merged to main and is an ancestor of this branch. The min type list hint goes to stderr, and a test pins that. No major problems, so no follow-ups are needed.
Earlier findings:
- Medium, constraints enforced with exit 3 (guide): fixed. The guide now says only that a
loadout_modeconstraint is refused, and the host-address network example is gone. - Medium, constraints enforced with exit 3 (reference): fixed. The reference limits the exit-3 refusal to
loadout_mode. - Medium, untested stderr and
-obehaviour of themin type listhint: fixed.cmd_type_list_intakes a stderr writer.type_list_hint_is_stderr_only_and_not_with_an_output_formatcovers no-o,-o json,-o yamland-o toml, plus a project that has its own type. - Low, the example's
own_ipdefault fails on VM hosts: fixed. The example type no longer sets a network. - Low, "fails to load in four cases": fixed. The count is gone, and the list now includes a key of the wrong shape and a constraint that widens its parent's.
Generated by Claude Code
Fixes #4020
Fixes #4022
What changes
docs/reference/minimal-dot-toml.mdNew
[sessions.<name>]section (minimal-dot-toml.mdhas a[tasks.*]section but no[sessions.*]section #4020), beside[tasks.*]. It covers how a session entry starts, an example, and a table of every key a session applies:type,descriptionand[box] name;packages,env_vars,patches,lifecycle_hooks,hooks_on_resumeandloadout_mode;lifetime,timeout,network,secretsandfile_exports.It also says that a session ignores a task's action keys, and points to
min box spec <name>for every value and its layer.New
[box_types.<name>]section (No user doc says how to define a box type; "box spec" leads only to the CLI page #4022). It covers:extends,defaults,constraintsanddescription);type =in[boxes.<name>];sessionroot starts withmin session startandmin box start. Ataskroot runs withmin task runandmin box start, and its defaults cannot setenv_varsorpatchesyet (feat(minimal): apply a task Box Type's default env_vars and patches to its task boxes #4031).agent,service,buildandcontainer-buildroots are refused.The Entry tables paragraph no longer names
on_oomand[machine]as entry settings, because no session applies them. It links the sessions table instead.docs/guide/box-types.md(new): a short walk-through. It defines acitype that extendstask, checks it withmin type listandmin type show, uses it in a[boxes.check]entry, previews it withmin box spec, and runs it withmin task run.docs/reference/cli-min.md: thebox specsection says Minimal renders the spec fromminimal.tomleach time and does not save it. It says where to change the spec, and links to the entry tables, the sessions section and the box types section. The tester's search for "box spec" landed here.min type list: with no project type, it prints on stderr: "No project box type is defined here. A [box_types.] table in minimal.toml defines one, with extends naming the type it builds on." stdout stays the table, so scripts are unaffected, and-o json|yaml|tomlprints no hint.type_list_shows_builtin_and_project_types_with_sourcepins the text, and also checks that a project with its own types gets no hint.How the keys were checked
I traced every key in
SPEC_KEYS(crates/mfile/src/expand.rs) on the session path at this branch's tip:box_entrysendspackages,lifecycle_hooks,env_varsandpatchesto the daemon.KEPT_EXPANDED_SECTIONSstoressecrets,env_varsandpatches.lifetimeandtimeoutare read by minimald'sends_with_entrypointandtimeout_of(box_actor/host.rs).file_exportsis copied by the attach.[box] nameis read byexpanded_box_name.machine,on_oom,nesting,volumes,otel,file_imports,github_imports,restart,exec_enabled), and the task-only keys.Rebuilt on
mainafter #4005 and #4008 squash-merged: the PR's own five files, applied unchanged, with the old head merged-s ours.Residuals
The user docs follow Karl's rule (2026-12-04): they state only how the software works, with no "not yet" or issue-number copy, and they don't mention keys that have no implementation. Follow-ups for those keys are tracked outside the docs:
BoxSpecdoc comments forlifetimeandtimeout(mfile/src/spec.rs) still say no launch reads them, but minimald does.loadout_modeare checked against entries. Until then, the docs describe constraints as theloadout_modelimit they are.The session key table lists
exec_enabled, which #4037 (merged) applies.Verification
cargo nextest run -p minimal: 1378 passed.-D warningsand fmt are clean.🤖 Generated with Claude Code
https://claude.ai/code/session_016CYvTye6pQuxGcVPkx1r2g
Summary by CodeRabbit