Repository navigation
Description
Problem or Motivation
Child 6 of the ADR modernization (#5233). Decision (owner direction of 2026-11-12). It waits for the owner's approval at the merge.
The review of each record that this item changes:
- ADR 0018 (supersede (command-gate record)): The fixed allow-list contradicts the owner direction of 2026-11-12. Keep the seven run-Job controls and 'no entry from issue or model text', and put the values in the manifest. Allow path options in the run Job only after feat(k8s): manifest and admission policy for planner sandboxed run job #4003 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147.
Proposed Solution & Architectural Design
A new record supersedes 0018. Allow and block lists live in settings and get entries only from a reviewed config. Jev judges every other command with a default of allow, and an error, a timeout or low confidence refuses. Shadow mode and an eval set come first. The seven controls stay, with their values in the CronJob template and in settings under an admission-policy ceiling. Path options are allowed in the run Job only after #4003 and #4147, and implement stays in shadow until #3694 and #3700 ship. SECURITY.md rule 6 says that the runner pod, not bubblewrap, holds the model's shell commands. The code comes in #4003, #4006, #4007, #4098 and #4147.
Rules of the ADR process (docs/adr/README.md, #5225) that apply:
- Supersession: the new record sets 'supersedes', and the same PR sets status and 'superseded-by' on the old record. The test fails on a link that goes only one way. The new record restates each rule and each rejected option that still holds, because the alternatives check drops superseded records. Never amend a superseded record. After a third amendment, or when a body contradicts the code, the next change is a supersession.
- Length: the body of a new record has 1,000 words or fewer, its title has 10 words or fewer, and its slug has 60 characters or fewer. Designs, catalogues, row tables, cutover plans, caps and measurements go to OpenSpec changes and specs, to settings or to docs, with a link under More Information.
- Use one Considered Options section. Each bullet ends with 'chosen.', 'rejected, because .' or 'deferred until .'. 'Deferred' does not match the rejected regex (adr.py:49), so the check stops refusing on a premise that changed. Each record has a Confirmation section that names its test, CI row or metric, and an optional tracker key.
- Code, tests and workflows cite the record in force. A test fails on a citation of a superseded record in src/, tests/ and .github/ (archived changes and CHANGELOG.md are history). Each superseding PR moves the citations of the records that it supersedes. Rename sweeps do not change docs/adr/.
- Merge ADR changes in batches. Each change of the ADR set changes adr_hash (alternatives.py:634-644, 1006) and makes every checked item due again. So all pure status changes go in docs(adr): add MADR front matter, a Status History and the ADR rules #5225, and the record PRs merge one at a time in the planned order.
- Keep the fix(roadmap): the ADRs in force fill the alternatives ADR budget #5049 budget test. A new record must fit in the tokens that the records it supersedes free. Short option bullets keep the budget, because options are 6,883 of the 8,464 tokens today.
Keep these constraints on purpose. The review found a reason for each one:
- ADR 0018, the seven run-Job controls, no run in the Service pod or in the stage Job (which holds the GitHub token, the gateway key and egress), and no list entry from issue or model text.
The owner merges this pull request.
Target Subsystem
docs/adr/, SECURITY.md.
Existing Tool Considered
MADR 4 and the rules of docs/adr/README.md (#5225). No new tool.
Acceptance Criteria
- A new record supersedes ADR 0018. Allow and block lists live in settings and get entries only from a reviewed config. Jev judges every other command with a default of allow, and an error, a timeout or low confidence refuses. Shadow mode and an eval set come first.
- The seven run-Job controls stay, with their values in the CronJob template and in settings under an admission-policy ceiling.
- The record allows path options in the run Job only after feat(k8s): manifest and admission policy for planner sandboxed run job #4003 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147, and keeps implement in shadow until feat(roadmap): test sandboxd and add the shell command backend #3694 and feat(roadmap): add the three-container runner Job, policy and log reads #3700 ship.
-
SECURITY.mdrule 6 says that the runner pod, not bubblewrap, holds the shell commands of the model. - The index and link tests of docs(adr): add MADR front matter, a Status History and the ADR rules #5225 pass, and the fix(roadmap): the ADRs in force fill the alternatives ADR budget #5049 budget test passes: the alternatives check fits every record in force under its cap.
Dependencies
-
chore(roadmap): hold incremental stage and implement work #6521 (hold: incremental work on the stage, implement and fix-checks jobs waits for the re-architecture)
-
docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239
Related
- Tracker: docs(adr): track the ADR modernization #5233. Review source:
docs/adr/at e413c40. - The code comes in feat(k8s): manifest and admission policy for planner sandboxed run job #4003, feat(roadmap): output truncation and secret masking for planner run tool #4006, test(roadmap): proof tests for planner sandboxed run job isolation controls #4007, feat(roadmap): wire sandboxed run tool into stage toolbox and prompt #4098 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147. feat(roadmap): check shell commands with a parser and configured lists #5201 checks shell commands with a parser and configured lists.
Source: #5233
Alternatives check of 2026-11-22: not-applicable.
Class: docs, no search.
Tool: none found.
Proposed design
Problem statement
ADR 0018 fixes an allow-list for the planner run Job. The owner direction of 2026-11-12 changes the command gate to lists in settings and to Jev as a default-allow judge. This item adds one new record that supersedes ADR 0018, keeps the seven run-Job controls, moves the citations of ADR 0018 and corrects SECURITY.md rule 6. It waits for #6521 and #5239.
Acceptance criteria
Requirement: Two-way supersession of ADR 0018
The new record SHALL set supersedes: ["0018"], and the same pull request SHALL set status: superseded and superseded-by to the new record on ADR 0018.
Scenario: Two-way supersession link
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns ondocs/adr/ - THEN The test reports no missing back link and no superseded record without a
superseded-byentry.
Requirement: The body of ADR 0018 does not change
The pull request SHALL NOT change the body of ADR 0018, so its body-hash SHALL stay valid after the supersession.
Scenario: Body hash of the superseded record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns ondocs/adr/ - THEN The test reports no
body-hashmismatch for ADR 0018.
Requirement: Front matter of the new record
The new record SHALL set date: 2026-11-12, decision-makers: [owner], issue: 5241, tracker: 5233, status: accepted and a valid body-hash.
Scenario: Front matter of the new record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns on the new record - THEN The test reports no missing or wrong front matter field and no
body-hashmismatch for the new record.
Requirement: The new record fits the length limits
The new record SHALL have a title of 10 words or fewer, a slug of 60 characters or fewer and a body of 1,000 words or fewer.
Scenario: Length of the new record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns on the new record - THEN The test reports no title, slug or body length problem for the new record.
Requirement: The index lists the new record and the superseded status
The generated ADR index SHALL list the new record and SHALL show ADR 0018 as superseded.
Scenario: Index and links of the new record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns ondocs/adr/ - THEN The test reports no missing index row for the new record and no broken ADR link.
Requirement: The lists live in settings and take only reviewed entries
The new record SHALL state that the allow list and the block list live in settings, that an entry comes only from a reviewed config, and that no entry comes from an issue or from model text.
Scenario: The list rule in the record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns with the new list content case - THEN The content case reports no missing phrase for the allow list, the block list, settings, the reviewed config, the issue and the model text.
Requirement: Jev judges every other command with a default of allow
The new record SHALL state that Jev judges each command that no list names with a default of allow, that an error, a timeout or a low confidence refuses the command, and that shadow mode and an eval set come first.
Scenario: The Jev policy in the record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns with the new Jev content case - THEN The content case reports no missing phrase for the default of allow, the error, the timeout, the low confidence, the refusal, shadow mode and the eval set.
Requirement: The seven run-Job controls stay
The new record SHALL keep the seven run-Job controls of ADR 0018, SHALL place their values in k8s/devops/roadmap-service/cronjob-planner-run.yaml under the ceiling of k8s/devops/roadmap-service/admissionpolicy.yaml, and SHALL keep the rule that no run happens in the Service pod or in the stage Job.
Scenario: The seven controls in the record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns with the new controls content case - THEN The content case reports no missing phrase for the seven controls, the two manifest paths, the Service pod and the stage Job.
Requirement: Path options and implement wait on their issues
The new record SHALL allow path options in the run Job only after #4003 and #4147, and SHALL keep implement in shadow until #3694 and #3700 ship.
Scenario: The conditions in the record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns with the new condition content case - THEN The content case reports no missing condition for feat(k8s): manifest and admission policy for planner sandboxed run job #4003, feat(k8s): render a credential-free ConfigMap for the planner run Job #4147, feat(roadmap): test sandboxd and add the shell command backend #3694 and feat(roadmap): add the three-container runner Job, policy and log reads #3700.
Requirement: Rule 6 names the runner pod
SECURITY.md rule 6 SHALL state that the runner pod, not bubblewrap, holds the model's shell commands, and SHALL keep bubblewrap for the executable verification criteria and the review tools.
Scenario: Rule 6 of SECURITY.md
- WHEN
uv run devops ci test tests/invariants/test_security_policy.pyruns with the new rule-6 case - THEN The test passes and reports that rule 6 names the runner pod and keeps bubblewrap for the executable verification criteria and the review tools.
Requirement: Each option bullet ends with a verdict
The new record SHALL use one Considered Options section, and each bullet of that section SHALL end with chosen., rejected, because <reason>. or deferred until <condition>..
Scenario: Ending of an option bullet
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns on the new record - THEN The test reports no option bullet with another ending.
Requirement: The new record restates the rules and rejected options of ADR 0018
The new record SHALL restate each rule and each rejected option of ADR 0018 that still holds.
Scenario: Restatement of ADR 0018
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns with the new restatement content case - THEN The content case reports no missing rule or rejected option that the new record must restate.
Requirement: The new record has a Confirmation section
The new record SHALL have a Confirmation section that names its test, CI row or metric, and an optional tracker key.
Scenario: Confirmation section of the new record
- WHEN
uv run devops ci test tests/invariants/test_adr_records.pyruns on the new record - THEN The test reports no missing Confirmation section for the new record.
Requirement: The citations of ADR 0018 move
The pull request SHALL move each citation of ADR 0018 in src/, tests/ and .github/ to the new record.
Scenario: Citation of a superseded record
- WHEN
uv run devops ci test tests/invariants/test_adr_superseded_citations.pyruns on the tree - THEN The test reports no citation of a superseded record in
src/,tests/or.github/.
Requirement: The record set fits the token budget
The new record SHALL fit in the tokens that ADR 0018 frees, so fit_to_budget SHALL leave out no record in force.
Scenario: Token budget of the records in force
- WHEN
uv run devops ci test tests/roadmap/test_roadmap_alternatives.pyruns withCONST_ROADMAP_ALTERNATIVES_MAX_ADR_TOKENS - THEN The test reports no record left out and no failure of the token cap.
Existing Tool Considered
The alternatives check of 2026-11-22 in the issue body gives not-applicable: class docs, no search, tool none found. No open tool covers the need, because the change writes one decision record and edits one policy line. The project writes its records with the MADR 4 template that docs/adr/README.md names. This change builds no code, so it has no build cost in tokens or in time: the work is one record, one SECURITY.md edit and their content cases.
Key questions
- Which record does the new record supersede, and what does that record hold?: ADR 0018,
docs/adr/0018-a-sandboxed-read-only-run-tool-for-the-planner.md, holds a fixed allow-list, seven isolation controls, a separate Kubernetes Job, output caps andmask_secrets. It also holds the owner decision that rejects bubblewrap and unshare, the rejected options and a Status History section. The new record restates each rule and each rejected option that still holds, because the alternatives check reads only the records in force. [sources: docs/adr/0018-a-sandboxed-read-only-run-tool-for-the-planner.md, docs/adr/README.md] - Which number, title, slug and front matter does the new record take?: Use the next free number after docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239 merges. Do not reserve 0029 now. Use the title
The command gate is a decision point: lists, then Jev(10 words) and the slugthe-command-gate-is-a-decision-point-lists-then-jev(51 characters). Setstatus: proposeduntil the checks pass, thenstatus: acceptedand thebody-hash. Setdate: 2026-11-12,decision-makers: [owner],issue: 5241,tracker: 5233andsupersedes: ["0018"]. (best practice) [sources: docs/adr/README.md, docs/adr/0001-github-is-the-roadmap-source.md]- Chosen: Next free number after docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239 merges. The dependency docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239 can add a record first. The number stays correct after docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239 merges, and the title and the slug fit the limits.
- Rejected: Reserve 0029 now. docs(adr): one decision-model record supersedes ADR 0019 and ADR 0020 #5239 can take 0029 first. A reserved number can name a record that another change writes.
- Where do the allow list and the block list hold their values?: The allow list and the block list live in settings. An entry comes only from a reviewed config. The record states the rule and links to the settings under More Information. The values of the seven run-Job controls stay in
k8s/devops/roadmap-service/cronjob-planner-run.yaml, under the ceiling ofk8s/devops/roadmap-service/admissionpolicy.yaml. The record holds no table of values. (best practice) [sources: docs/adr/README.md, k8s/devops/roadmap-service/cronjob-planner-run.yaml, k8s/devops/roadmap-service/admissionpolicy.yaml]- Chosen: Values in settings and the CronJob template. The rule stays in the record, and each value stays next to the code that reads it. The ADR length rule sends a table and a cap to settings or docs.
- Rejected: Values in the ADR body. The ADR length rule sends a table and a cap to settings or docs. A copy in the record would drift from the manifest.
- Which Jev policy does the record state?: Jev judges each command that no list names, and its answer defaults to allow. An error, a timeout or a low confidence refuses the command. Shadow mode and an eval set come first. Rule 7 of ADR 0019 keeps a Jev answer as evidence and never as the only control, and the new record keeps that rule. (best practice) [sources: docs/adr/0019-a-decision-step-asks-jev-short-closed-questions-about-evidence-that-tools-extract.md, docs/guidelines/agentic-jobs.md, SECURITY.md]
- Chosen: Default allow, and refuse a command that no rule and no model judged. The owner direction of 2026-11-12 names default allow. A security control refuses a command that no rule and no model judged.
- Rejected: Default deny. It refuses the commands that the runner runs today, before the eval set of shadow mode exists.
- Rejected: Fail open on an error, a timeout or a low confidence. It admits a command that no rule and no model judged. Rule 7 of ADR 0019 refuses a Jev answer as the only control.
- Which run-Job controls does the record keep?: Keep the seven controls of ADR 0018. Their values stay in the CronJob template and in the admission policy. No list entry comes from an issue or from model text. Jev is a model and never the only control, so the controls stay beside it. (best practice) [sources: docs/adr/0018-a-sandboxed-read-only-run-tool-for-the-planner.md, docs/adr/0019-a-decision-step-asks-jev-short-closed-questions-about-evidence-that-tools-extract.md, CONTEXT.md, k8s/devops/roadmap-service/admissionpolicy.yaml]
- Chosen: Keep the seven controls of ADR 0018. Each control closes one way that a run does harm, and the runner pod is the sandbox.
- Rejected: Replace the controls with the judgement of Jev. A model is no security boundary, and rule 7 of ADR 0019 refuses a Jev answer as the only control.
- Does the record allow path options in the run Job now?: No. Allow path options in the run Job only after feat(k8s): manifest and admission policy for planner sandboxed run job #4003 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147 ship. Keep
implementin shadow until feat(roadmap): test sandboxd and add the shell command backend #3694 and feat(roadmap): add the three-container runner Job, policy and log reads #3700 ship. A path that a model gives is untrusted input, and the parser and the configured lists are not in force yet. (best practice) [sources: docs/adr/0018-a-sandboxed-read-only-run-tool-for-the-planner.md, SECURITY.md]- Chosen: Defer path options until feat(k8s): manifest and admission policy for planner sandboxed run job #4003 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147 ship. A path from a model is untrusted input, and the parser and the configured lists are not in force yet.
- Rejected: Allow path options now. The parser and the configured lists of feat(k8s): manifest and admission policy for planner sandboxed run job #4003 and feat(k8s): render a credential-free ConfigMap for the planner run Job #4147 are not in force.
- How does SECURITY.md rule 6 change?: Rule 6 states that the runner pod holds the shell commands of the model, because the shell of a step checks only the first word of a command and is no security boundary. Bubblewrap stays for the executable verification criteria and for the review tools, which rule 7 keeps in the sandbox. (best practice) [sources: SECURITY.md, CONTEXT.md]
- Chosen: Name the runner pod and keep bubblewrap for the criteria and the review tools. CONTEXT.md says the runner pod is the sandbox, and rule 7 keeps the review tools in bubblewrap.
- Rejected: Delete rule 6. The verification criteria and the review tools still need the sandbox.
- Which citations move in this pull request?: Move each citation of ADR 0018 in
src/,tests/and.github/to the new record in this pull request. Keep the citations in the archived changes and inCHANGELOG.md, because they are history. Leavedocs/adr/out of a rename sweep. (best practice) [sources: docs/adr/README.md, openspec/specs/adr-records/spec.md]- Chosen: Move each citation in src/, tests/ and .github/ now. The record rule makes the superseding pull request move the citations, and a later sweep would leave the default branch red.
- Rejected: Leave the citations to a later sweep. A citation of a superseded record is a defect in the record set, and a later sweep adds a second pull request for the same item.
- Does the record restate the rules and rejected options of ADR 0018?: Yes. The new record restates each rule and each rejected option that still holds, because the alternatives check reads only the records in force. The pull request does not amend ADR 0018: it sets
supersedeson the new record and leaves the body and thebody-hashof ADR 0018 unchanged. (best practice) [sources: docs/adr/README.md, docs/adr/0001-github-is-the-roadmap-source.md]- Chosen: Restate each rule and rejected option that still holds. The alternatives check drops a superseded record, so a rule that the new record does not restate is lost to the check and to a reader of the records in force.
- Rejected: Cite ADR 0018 and keep the new body short. A reader of the records in force would not find the rule, and the alternatives check would not read it.
- How does the new record fit the ADR token budget?: Keep the body at 1,000 words or fewer and keep the Considered Options bullets short. Put the details of the controls and the lists in settings and in docs under More Information. The new record then fits in the tokens that ADR 0018 frees, so
fit_to_budgetleaves out no record in force. (best practice) [sources: docs/adr/README.md, src/devops_cli/roadmap/alternatives.py]- Chosen: Short option bullets and a body under 1,000 words. Options are the largest part of the token cap, and a short record fits in the tokens that ADR 0018 frees.
- Rejected: Copy the seven controls, their values and the lists into the record. The length rule sends tables and caps to settings or docs, and a long record would push older records out of the alternatives check.
- Who approves the record, and how?: The owner merges the pull request, and the merge is the approval. The pull request opens as a draft with
status: proposed. The agent setsstatus: acceptedand thebody-hashwhen the checks pass. (best practice) [sources: AGENTS.md, docs/adr/README.md]
Fit
Fits in one pull request.
Suspected block
None.
Activity
dan-petty commentedon Nov 12, 2026
adr, and .github/labels.yml declares no scope/adr label. Add the label to the file to give the scope to this item.Both concern the command gate with Jev judgment, but the candidate delivers an ADR record while #5206 delivers the Jev feature code.devops-cli-service commentedon Nov 16, 2026
Alternatives check: not-applicable
Class: docs. The check makes no search and no model call for an item of this class.
Tool: none found
Checked on 2026-11-16. A person decides what this means for the item. The check changes no label and closes no issue.
devops-cli-service commentedon Nov 17, 2026
Owner question: Who approves the record, and how? (a person decides)
Options
Recommendation: Decide the question: only a person can answer it.
Evidence
dan-petty commentedon Nov 20, 2026
Frozen on 2026-11-20. The stage, implement and fix-checks jobs grade under 60%, so the owner rule asks for a re-architecture before more fixes inside the current design (tracker #6519). This item is incremental work on those jobs, so its Dependencies section now names #6521 first. Stage and implement leave this item while #6521 is open. When the experiments of #6519 decide, a person closes #6521 (this item can then continue) or closes this item as not planned.
devops-cli-service commentedon Nov 21, 2026
Owner question: See the first point of Open questions in the section Proposed design of the body.
Options
Recommendation: Decide the question: only a person can answer it.
Evidence
dan-petty commentedon Nov 24, 2026
The owner merges the pull request. Only a person merges pull requests (AGENTS.md).
devops-cli-service commentedon Nov 24, 2026
Next step: the open items close, or a person replies in a comment or edits the body. See Dependencies in the section Proposed design of the body.