Skip to content

feat(runtime): prepare Node stages and honor project tool choices - #287

Merged
datacas merged 7 commits into
mainfrom
issue-279-sandbox-dependency-setup
Oct 20, 2026
Merged

datacas merged 7 commits into
mainfrom
issue-279-sandbox-dependency-setup

Conversation

@datacas

@datacas datacas commented Oct 20, 2026 •

Copy link
Copy Markdown
Owner

Native stages currently lose explicitly selected tools at the command table and start cold Node clones without dependency setup. This change carries project choices into stage policies and native permission profiles, and runs frozen, script-disabled preparation before native writing/review stages.

Work item: #279

Closes #279

Status: BLOCKED — draft, native acceptance validation incomplete. Ordinary local checks pass; the required live campaign cannot complete in this executor. This is not an approval or a claim that either native installation succeeded.

Routing: profile deep_coder, requested model openai/gpt-6.1-sol, effort medium, resolved model ?.

Changes

  • Add validated code_cycle.user_choices for executables, command prefixes, MCP integrations and exact registry hosts, serialized into every stage policy. Preserve direct Git, publication and Docker checks, and provide permitted search fallback guidance.
  • Prepare pnpm/npm/Yarn lock roots and workspace package locations in restricted native sandboxes; disable lifecycle scripts, retry transient failures once, preserve command/log/exit/HEAD evidence, and verify cached installs before reuse. Fresh clones get their own dependency trees; pnpm does not hard-link them into the shared store.
  • Give non-publishing Codex issue review explicit code-host networking. Align issue-review's environment-blocker validator with recovery guidance. Grant native Write/Edit helper paths consistently with the existing TMPDIR hook rules.
  • Keep publication-aware reroute stops and explain when an environment failure has already published. Ship the modules in the installed runtime and assign the new tests to Windows CI.

Diagnosis

Decision: implement_root_fix; classification: shared_cause. The reported invariant is that a requested cycle can perform authorized routine setup and preserve progress without per-executable approval churn. The baseline policy tests (rtk proxy python3 -m unittest tests.test_stage_permissions tests.test_issue_review, 129 passing assertions) confirm the existing refusal of unconfigured execution; source inspection confirms that _isolated_review_dispatch checks out HEAD without preparation and Codex's explicit code-host route depends on publication. This matches the issue's mechanism. The production Nuxt registry failure was not independently reproduced here.

The widened related-work search covered the linked issues, open/closed sandbox issues and merged sandbox PRs. Scope overlaps #267, #275 and #280; #268's publication invariant is preserved. #274's earlier suite incompatibility and #282/#284/#285 remain distinct. Relevant merged work includes #221, #232, #239 and #277. No related item is closed by this PR.

Work units

Unit Behaviour Files Tests Verification Rollback
WU-1 Carry effective project authorization and prepare cold native Node stages with honest recovery evidence scripts/{user_choices,dependency_setup,stage_permissions,executors,run_cycle,issue_review,cycle}.py, runtime/shard manifests, docs and regression tests manager detection, retries/cache integrity, clean review/rereview clones, monorepo outputs, process failures, selected tools through both Claude barriers, malformed blocker/config rejection Ordinary suite/static checks pass; live native campaign blocked as listed below Independent: revert commit 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8

Verification — agent-reported

Level Exact command Exit Executed
test rtk proxy python3 -m unittest discover -s tests > "$TMPDIR/unittest-discover.log" 2>&1 0 1,628 tests
static rtk proxy python3 scripts/validate-package.py > "$TMPDIR/validate-package.log" 2>&1 0 n/a
test rtk proxy python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_issue_review tests.test_validate_workflow > "$TMPDIR/final-targeted.log" 2>&1 0 102 tests
boundary rtk proxy python3 -m unittest tests.test_stage_dispatch.ClaudePolicyTests.test_project_choices_reach_both_barriers_and_private_registry_profile > "$TMPDIR/choice-boundary.log" 2>&1 0 1 test
boundary rtk proxy python3 -m unittest tests.native_dependency_campaign > "$TMPDIR/native-campaign.log" 2>&1 1 2 tests, both failed before install

The full suite finished before the final added dispatch test; that test and its affected path were then executed separately. Fixtures set their own Git identity and do not require the user's global identity or warmed Node dependencies. The ordinary subprocess fixtures do not establish real OS confinement. BasedPyright was not run: it is outside this stage's configured verification commands.

Native campaign blocker and remaining validation

The opt-in cold-workspace campaign records fixture HEAD f118814ea96742267e54bee8a9c534d715e74668. Codex's actual sandbox wrapper exited 1 with error building bubblewrap command: app-server socket directory must be a user-owned directory with mode 0700. Claude's actual wrapper was not launched because srt is unavailable (exit status null). No native install or dependency lookup passed. No sandbox variants were retried after the observed socket restriction.

See docs/dependency-preparation-campaign.md for the observed command/results, and docs/dependency-preparation.md for the repeatable host campaign. Run it from an authorized executor with functioning native sandboxes and srt available, then attach install/verification logs and exact HEAD evidence. Lifecycle/native builds detected after script-disabled installation remain explicitly incomplete until recovered within a contained build path; no such build is claimed here.

CI policy is parallel: the pushed-head checks will be read once and recorded in the stage summary; this stage will not wait for them. Pending checks remain pending.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Native stages currently lose explicitly selected tools at the command table and start cold Node clones without dependency setup. This change carries project choices into stage policies and native permission profiles, and runs frozen, script-disabled preparation before native writing/review stages.

Work item: #279

Status: BLOCKED — draft, native acceptance validation incomplete. Ordinary local checks pass; the required live campaign cannot complete in this executor. This is not an approval or a claim that either native installation succeeded.

Routing: profile deep_coder, requested model openai/gpt-6.1-sol, effort medium, resolved model ?.

Changes

  • Add validated code_cycle.user_choices for executables, command prefixes, MCP integrations and exact registry hosts, serialized into every stage policy. Preserve direct Git, publication and Docker checks, and provide permitted search fallback guidance.
  • Prepare pnpm/npm/Yarn lock roots and workspace package locations in restricted native sandboxes; disable lifecycle scripts, retry transient failures once, preserve command/log/exit/HEAD evidence, and verify cached installs before reuse. Fresh clones get their own dependency trees; pnpm does not hard-link them into the shared store.
  • Give non-publishing Codex issue review explicit code-host networking. Align issue-review's environment-blocker validator with recovery guidance. Grant native Write/Edit helper paths consistently with the existing TMPDIR hook rules.
  • Keep publication-aware reroute stops and explain when an environment failure has already published. Ship the modules in the installed runtime and assign the new tests to Windows CI.

Diagnosis

Decision: implement_root_fix; classification: shared_cause. The reported invariant is that a requested cycle can perform authorized routine setup and preserve progress without per-executable approval churn. The baseline policy tests (rtk proxy python3 -m unittest tests.test_stage_permissions tests.test_issue_review, 129 passing assertions) confirm the existing refusal of unconfigured execution; source inspection confirms that _isolated_review_dispatch checks out HEAD without preparation and Codex's explicit code-host route depends on publication. This matches the issue's mechanism. The production Nuxt registry failure was not independently reproduced here.

The widened related-work search covered the linked issues, open/closed sandbox issues and merged sandbox PRs. Scope overlaps #267, #275 and #280; #268's publication invariant is preserved. #274's earlier suite incompatibility and #282/#284/#285 remain distinct. Relevant merged work includes #221, #232, #239 and #277. No related item is closed by this PR.

Work units

Unit Behaviour Files Tests Verification Rollback
WU-1 Carry effective project authorization and prepare cold native Node stages with honest recovery evidence scripts/{user_choices,dependency_setup,stage_permissions,executors,run_cycle,issue_review,cycle}.py, runtime/shard manifests, docs and regression tests manager detection, retries/cache integrity, clean review/rereview clones, monorepo outputs, process failures, selected tools through both Claude barriers, malformed blocker/config rejection Ordinary suite/static checks pass; live native campaign blocked as listed below Independent: revert commit 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8

Verification — agent-reported

Level Exact command Exit Executed
test rtk proxy python3 -m unittest discover -s tests > "$TMPDIR/unittest-discover.log" 2>&1 0 1,628 tests
static rtk proxy python3 scripts/validate-package.py > "$TMPDIR/validate-package.log" 2>&1 0 n/a
test rtk proxy python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_issue_review tests.test_validate_workflow > "$TMPDIR/final-targeted.log" 2>&1 0 102 tests
boundary rtk proxy python3 -m unittest tests.test_stage_dispatch.ClaudePolicyTests.test_project_choices_reach_both_barriers_and_private_registry_profile > "$TMPDIR/choice-boundary.log" 2>&1 0 1 test
boundary rtk proxy python3 -m unittest tests.native_dependency_campaign > "$TMPDIR/native-campaign.log" 2>&1 1 2 tests, both failed before install

The full suite finished before the final added dispatch test; that test and its affected path were then executed separately. Fixtures set their own Git identity and do not require the user's global identity or warmed Node dependencies. The ordinary subprocess fixtures do not establish real OS confinement. BasedPyright was not run: it is outside this stage's configured verification commands.

Native campaign blocker and remaining validation

The opt-in cold-workspace campaign records fixture HEAD f118814ea96742267e54bee8a9c534d715e74668. Codex's actual sandbox wrapper exited 1 with error building bubblewrap command: app-server socket directory must be a user-owned directory with mode 0700. Claude's actual wrapper was not launched because srt is unavailable (exit status null). No native install or dependency lookup passed. No sandbox variants were retried after the observed socket restriction.

See docs/dependency-preparation-campaign.md for the observed command/results, and docs/dependency-preparation.md for the repeatable host campaign. Run it from an authorized executor with functioning native sandboxes and srt available, then attach install/verification logs and exact HEAD evidence. Lifecycle/native builds detected after script-disabled installation remain explicitly incomplete until recovered within a contained build path; no such build is claimed here.

Published head and checks

Draft PR #287: #287

Head: 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8. GitHub confirms this exact SHA. The remote push succeeded; the optional local upstream setting could not be saved because the shared Git config is read-only. Continue using the explicit branch and PR.

CI policy is parallel. Read once after publication: 0 passed, 0 failed, 5 pending. This stage does not wait or turn pending results into passes.

Check State
Skills, manifests, and Bash installer pending
Windows test shard (windows-1) pending
Windows test shard (windows-2) pending
Windows test shard (windows-3) pending
Windows test shard (windows-4) pending

Functional status remains BLOCKED for the required native campaign. No finding resolutions are claimed by this implement attempt.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Initial review — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: CHANGES_REQUESTED. Head 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 was reviewed in full. Three open findings block approval.

Summary and scope

I read the complete accumulated diff against origin/main: merge base bbd3149274f07591f30e1374d3188778e243bad6, 1492 lines (runtime-supplied file, line count confirmed). It covers the new scripts/dependency_setup.py and scripts/user_choices.py, plus changes to executors.py, stage_permissions.py, run_cycle.py, issue_review.py, cycle.py, the manifests, docs and tests. The user_choices validation, the reordering of the Git/gh/Docker guard ahead of user choices, the issue-review environment_blocker validation, the Write/Edit TMPDIR helper parity and the reroute diagnostic are sound. The problems are in the Codex network profile, the size of the Codex preparation argv, and missing coverage of the preparation wiring.

Findings

[REV-001] · high · open · - · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py:1167-1169, scripts/executors.py:1819-1834

NativeAdapter.dispatch sets network_domains whenever command_policy is not None, whatever the value of publishes and whether or not the policy is active. In CodexAdapter.argv, network_domains is not None now selects code_cycle_publish_read/code_cycle_publish_write with github.com, api.github.com, bitbucket.org and api.bitbucket.org allowed. Codex has no command table here: it runs with --ignore-rules and no hook, so the network-less sandbox was the only thing that stopped a non-publishing Codex stage from writing to the code host. The gh/Git credentials remain readable under :read-only/:workspace, and dispatch_environment strips nothing. The stages affected:

  • issue_review, security and bootstrap (ROLE_CONTRACTS in cycle.py:120-124: "publishes nothing, not even a comment");
  • every stage in a local_only cycle (cycle.py:431: publishes = contract.publishes and not self.local_only), including Codex implement/resolve writers, which can now git push/gh pr create;
  • the elif review_clone and not writes branch (code_cycle_review_read) can no longer be reached by any Codex review that has a policy.

At the HTTP layer, a domain allowlist cannot tell a code-host read from a write. So the docs' claim of "code-host read networking without publication rights" (docs/host-permissions.md, docs/dependency-preparation.md) is not enforced. It also contradicts docs/routing.md:203 ("A non-publishing writer moves to a :workspace profile whose proxy allows no domain").

Evidence: the passing test tests.test_dependency_setup.ChoiceTests.test_nonpublishing_codex_has_code_host_route_and_registry_choice asserts that a publishes=False read-only argv carries api.github.com under code_cycle_publish_read. The wiring in dispatch was confirmed by code inspection.

Expected fix: grant code-host domains only where the stage contract needs them. That means publishing stages, plus a deliberately scoped read path for issue_review that does not expose write credentials (for example a read-only token, or keeping issue reads on the host side). Registry domains alone should not turn a non-publishing stage into a publish profile. Add a regression test that local-only and issue-review Codex dispatches get no code-host route.

[REV-002] · medium · open · - · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py:358-368, scripts/dependency_setup.py:451-454

prepare sets protected to every path from git ls-files plus .git. For Codex, sandbox_command serialises all of them into the single argument permissions.code_cycle_prepare.filesystem={"<abs path>"="read",...}. On Linux a single argv string is limited to MAX_ARG_STRLEN (131072 bytes). At about 100 bytes per entry (absolute path plus quoting), a repository with roughly 1,300 tracked files already exceeds it. execve then fails with E2BIG, _run raises OSError, the version probe records exit_code: null, and preparation is reported incomplete before any package manager runs. Typical Nuxt/monorepo checkouts, the motivating case of #279, are well above that size. The listing is also mostly redundant: the profile already extends :read-only, so only tracked paths inside the writable outputs (node_modules, .yarn, .pnp.*) need an explicit read rule. Claude's srt path writes the list to a settings file and is not affected.

Evidence: code inspection. No large-repo fixture or native Codex run was possible here (see Unverified).

Expected fix: protect only the tracked paths under the writable outputs (or the outputs' tracked parents), and add a test with many tracked files that asserts the argv entry stays bounded.

[REV-003] · medium · open · - · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_dependency_setup.py:167-204, scripts/executors.py:1215-1235

test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies calls ds.prepare(...) inside its own fake dispatch_call. It would pass unchanged if NativeAdapter.dispatch never called dependency_setup.prepare. No test asserts the runtime behaviour of executors.py:1215-1235:

  • role gating (WRITING_ROLES | REVIEW_ROLES);
  • preparation running in the review clone rather than the source checkout;
  • the evidence notice reaching the Claude -p prompt and the Codex final prompt argument;
  • policy_note["dependency_preparation"];
  • the incomplete path when prepare raises.

A search of tests/ for dependency_setup.prepare, dependency_preparation and the notice text finds only direct calls. This wiring is the central behaviour the PR adds, and its work-unit table claims "clean review/rereview clones" as tested.

Expected fix: add dispatch-level tests that drive ClaudeAdapter/CodexAdapter.dispatch (and _isolated_review_dispatch) on a lockfile fixture with a fake sandbox binary. They should assert where preparation ran, which roles get it, and that the notice reached the prompt.

[REV-004] · low · open · - · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

scripts/stage_permissions.py:479-492, docs/dependency-preparation.md ("Choices do not grant force-pushes, merges…")

The Git/gh/Docker guard inspects only words[0]. If a project selects a wrapper or interpreter such as env, sh, bash, xargs, npx or python3, the hook allows commands like env git push --force or python3 -c "…gh pr merge…". That is a real authorization choice by the user, but the documentation states an unconditional guarantee. Either document that interpreter/wrapper choices void the publication boundary, or reject or warn on known command-running executables in user_choices.load.

Security triage

The audit ran. .code-cycle.yml declares no security_review.always_when rule, so the default triggers apply. The reviewer's own reading also activated it: the change touches the permission/command table, sandbox network profiles, credential handling during installs, and security tooling. The cc-security-review pass was run inline by this reviewer rather than as a separately loaded delegate. Result: REV-001 is a confirmed boundary regression (non-publishing Codex stages can reach the code host with the user's credentials) and REV-004 is a documentation overclaim. Other checks found no issue: preparation drops credential env vars (only PATH/LANG/proxy pass through, with HOME set to scratch), symlinked outputs are refused, and the review clone does not load PR-controlled .code-cycle.yml.

Commands executed

Command Exit Observed
python3 -m unittest discover -s tests 1 1629 tests: 1 failure, 62 errors, all environmental (below)
python3 scripts/validate-package.py 0 passed
python3 -m unittest 0 0 tests ran: default discovery from the repo root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_issue_review tests.test_stage_permissions tests.test_run_cycle 0 382 tests OK

Full-suite failures:

  • All 62 errors are in test_validate_package: shutil.copytree hits [Errno 13] Permission denied on sandbox-masked dotfiles in this review clone (.bashrc, .claude/settings.json, .mcp.json, …).
  • The one failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout ("no temporary directory outside the dispatch checkout"), because this reviewer's sandbox has no writable temp parent outside its allowed paths.

Neither module is touched by this PR. On Linux CI, Skills, manifests, and Bash installer passed.

Unverified

  • Native preparation through real codex sandbox and srt. Neither can run inside this review stage, and the author's own campaign (docs/dependency-preparation-campaign.md) is still BLOCKED. Release validation for Keep development moving through routine sandbox and dependency setup #279 remains open.
  • REV-002 was not reproduced by execution: no large-repo fixture or native Codex run was available.
  • The full suite outcome on this host is affected by the sandbox restrictions described above. The 382 targeted tests for the changed modules passed.

CI (parallel policy, read once, not waited on)

Check State
Skills, manifests, and Bash installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-3) pass
Windows test shard (windows-2) fail
Windows test shard (windows-4) fail
PowerShell installer fail

3 passed, 3 failed, 0 pending. windows-2 is the shard this PR assigned test_dependency_setup to. Under the parallel policy the cycle's CI gate, not this review, turns these failures into resolution work. The PR is still a draft.

Residual risk

  • Even after REV-001 is fixed, how issue_review reaches the code host needs a design decision: a read-scoped credential versus host-side reads.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design, so native-module projects remain locally unverifiable until a contained build path exists.

Verdict: CHANGES_REQUESTED — blocking: REV-001, REV-002, REV-003.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-initial-review","status":"CHANGES_REQUESTED","issue_provider":"github","issue_id":"279","code_host":"github","change_request_id":"287","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/287","pr_number":287,"issue_number":279,"head_sha":"4f1532a34b74984452a3b3e1d902cc61c2d4b0e8","reviewed_head_sha":"4f1532a34b74984452a3b3e1d902cc61c2d4b0e8","review_run_id":"CCR-20261020-001","reviewer":{"profile":"senior_reviewer","provider":"anthropic","model_requested":"claude-opus-5-5","model_resolved":null,"effort":"high"},"findings":[{"id":"REV-001","severity":"high","status":"open","disposition":"-","blocks_approval":true,"category":"security","path":"scripts/executors.py","line":1167},{"id":"REV-002","severity":"medium","status":"open","disposition":"-","blocks_approval":true,"category":"correctness","path":"scripts/dependency_setup.py","line":358},{"id":"REV-003","severity":"medium","status":"open","disposition":"-","blocks_approval":true,"category":"test-coverage","path":"tests/test_dependency_setup.py","line":167},{"id":"REV-004","severity":"low","status":"open","disposition":"-","blocks_approval":false,"category":"documentation","path":"scripts/stage_permissions.py","line":479}],"blocking_findings":["REV-001","REV-002","REV-003"],"checks":{"head_sha":"4f1532a34b74984452a3b3e1d902cc61c2d4b0e8","passed":3,"failed":3,"pending":0},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution blocked — PR #287 (work item #279)

Status: BLOCKED. No code changes, commits, pushes, or resolution claims were made in this attempt.

Routing: profile deep_coder, requested model openai/gpt-6.1-sol, effort high, resolved model ?.

The current PR head is 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8, matching the reviewed head and the clean linked worktree at .worktree/issue-279. The supplied accumulated diff's line count was confirmed as 1,492; only its first section was read before the blocker, so complete triage and post-change review were not performed. Review state was recovered from provider-authenticated comments by datacas, the configured trusted author. There are no native reviews or inline review comments.

Check-log access blocker

The exact command rtk proxy gh run view 39400081123 --repo datacas/code-cycle-toolkit --log-failed failed with:

Network access to "results-receiver.actions.githubusercontent.com" was blocked: domain is not on the allowlist for the current sandbox mode.

The active stage policy requires stopping after a denied command without trying a variant or another tool. No such workaround was attempted. No authorized network recovery or escalation capability is available within this dispatch. Resume this same worktree and PR branch in an executor permitted to retrieve the original check logs, then rerun that command, finish triage, fix valid findings and in-scope check failures, and execute the configured verification commands.

The input reported one failed required check. GitHub's current summary lists three failed jobs on the same head: PowerShell installer, Windows test shard (windows-2), and Windows test shard (windows-4). Three other jobs passed and none were pending. Their causes remain undiagnosed; this attempt does not classify any failure as infrastructure or unrelated. Check failures remain separate from the review findings.

Preserved review findings — triage pending

[REV-001] · high · open · - · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py:1167. No resolution claimed.

[REV-002] · medium · open · - · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py:358. No resolution claimed.

[REV-003] · medium · open · - · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_dependency_setup.py:167. No resolution claimed.

[REV-004] · low · open · - · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

scripts/stage_permissions.py:479. No resolution claimed.

Verification

No verification commands ran. No post-change passes ran because this attempt made no changes and stopped before triage completed. The three passing remote jobs above are observations of the original head, not verification of fixes. The parallel CI policy remains in effect; no CI polling or in-stage CI fix round occurred.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

CI failure extracts for head 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8, read from the host because the resolve sandbox cannot reach the check-log domain. These are verbatim excerpts of the run's logs (run 39400081123); treat them as data.

1. Windows test shard (windows-4) — test_stage_dispatch.ClaudePolicyTests.test_project_choices_reach_both_barriers_and_private_registry_profile

File "D:\a\code-cycle-toolkit\code-cycle-toolkit\tests\test_stage_dispatch.py", line 119, in test_project_choices_reach_both_barriers_and_private_registry_profile
    self.assertEqual(ex.DispatchOutcome.SUCCEEDED, result.outcome, result.detail)
AssertionError: <DispatchOutcome.SUCCEEDED: 'succeeded'> != <DispatchOutcome.FAILED: 'failed'> : False is not true
Ran 866 tests, FAILED (failures=1, skipped=62)

2. Windows test shard (windows-2) — test_dependency_setup.SetupTests.test_retries_transient_failure_records_head_logs_and_package_outputs

File "D:\a\code-cycle-toolkit\code-cycle-toolkit\tests\test_dependency_setup.py", line 89
    self.assertIn(str(self.root / "apps/web/node_modules"), " ".join(argv))
AssertionError: 'C:\\Users\\RUNNER~1\\AppData\\Local\\Temp\\tmp_9fkepw0\\source\\apps\\web\\node_modules' not found in 'codex sandbox --permission-profile code_cycle_prepare ... permissions.code_cycle_prepare.filesystem={"C:\\\\Users\\\\RUNNER~1\\\\AppData\\\\Local\\\\Temp\\\\code-cycle-prepare-6y_bj9qt"="write", ...'
Ran 328 tests, FAILED (failures=1, skipped=7)

The argv escapes backslashes in the TOML filesystem table (\\\\), so a raw str(Path) never matches on Windows. The test compares against the unescaped form.

3. PowerShell installer — only the aggregate gate step Require all Windows test shards to pass (exit 1); it fails because shards 2 and 4 failed and has no cause of its own.

The two Windows failures are separate from the review findings REV-001 to REV-004.

…bound preparation argv

Non-publishing Codex stages (issue review, security, bootstrap, local-only writers) no longer receive the default GitHub/Bitbucket domains; registry choices select a registry profile instead of a publication profile (REV-001). Codex preparation lists only tracked paths inside or above writable outputs, keeping the filesystem argument bounded on large repositories (REV-002). Dispatch-level tests cover preparation role gating, review-clone placement, prompt notice and the incomplete path (REV-003). Docs state that wrapper and interpreter choices trust nested operations (REV-004). Windows test fixes quote the helper path and compare the escaped TOML entry.

Refs #279
@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

Status: RESOLVED. Fix commit 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4, pushed to issue-279-sandbox-dependency-setup. All four findings and the two in-scope Windows CI failures were triaged against 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 before any edit.

The earlier attempt attempt-eb1a8ebfb14b45aab40da4a4ae9c379f published nothing: no comment carries its receipt. It did leave uncommitted edits in this work item's worktree (.worktree/issue-279). This attempt reviewed those edits line by line against each finding, verified them, and committed them as the fix commit above. Nothing was taken on trust.

Findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py:1167-1174, scripts/executors.py:1824-1843

  • NativeAdapter.dispatch now adds the default GitHub/Bitbucket domains only when publishes is true. Registry choices are the only domains a non-publishing stage gets.
  • CodexAdapter.argv picks the publication profile from publishes alone. A non-publishing stage with registry domains gets the new code_cycle_registry_read/code_cycle_registry_write profile, whose allowlist holds only the selected registries.
  • A non-publishing stage with no registry domains is back on the main-branch path: -s read-only/workspace-write, or code_cycle_review_read for a review clone, with no network.
  • Issue review is back to its main-branch behaviour, with no worker route to the code host. When the context it needs is missing, it reports environment_blocker (validated by this PR) instead of reading through write-capable credentials.
  • docs/dependency-preparation.md, docs/host-permissions.md and docs/routing.md now describe this boundary.

Regression tests:

  • test_stage_dispatch.DependencyPreparationDispatchTests.test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains covers every role, active and inactive policies, and with and without registries. Writers with publishes=False stand in for local-only cycles.
  • test_codex_publishing_dispatch_keeps_code_host_and_registry_domains checks that publishing stages keep both.
  • The former test_nonpublishing_codex_has_code_host_route_and_registry_choice now asserts the opposite and is renamed test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py:83-95

The Codex filesystem table now keeps a read rule only for a tracked path that sits inside a writable output, or that is an ancestor of one. :read-only already protects the rest of the checkout. Claude's srt settings file still gets the full denyWrite list.

Regression tests:

  • test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument uses 3,000 tracked source files, a listing that alone exceeds 128 KiB. It asserts the argument stays under 16 KiB, lists no source file, and still protects a tracked file under .yarn.
  • test_codex_protects_tracked_ancestors_of_writable_outputs covers the ancestor case.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py

  • test_preparation_role_gating_and_evidence_reach_each_native_prompt drives CodexAdapter.dispatch and ClaudeAdapter.dispatch for all seven roles. Preparation runs only for implement, resolve, review and rereview, with the policy's registry domains. The evidence notice reaches the Codex final argument and the Claude -p prompt, and artifacts["dependency_preparation"] is set.
  • test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent covers the incomplete path when prepare raises.
  • test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies now calls the real adapter.dispatch inside _isolated_review_dispatch. It asserts that prepare was called exactly once, with the clone path, that the agent ran in the clone with node_modules present, and that the notice carries the source head.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md

The docs now take the first option the review offered and drop the unconditional guarantee. The hook guards direct Git, code-host and Docker invocations. Selecting an interpreter, wrapper, arbitrary-code runner (python3, bash, env, xargs, npx) or an MCP integration trusts its nested operations, which the hook does not inspect. Rejecting such choices in user_choices.load was not done: it would change the user-choice contract this PR defines.

CI failures on 4f1532a (separate from the findings)

  • Windows test shard (windows-2), in this change's scope. test_retries_transient_failure_records_head_logs_and_package_outputs compared a raw str(Path) with the TOML-escaped argv entry. It now asserts the json.dumps(path) + '="write"' entry inside the permissions.code_cycle_prepare.filesystem= argument.
  • Windows test shard (windows-4), in this change's scope. test_project_choices_reach_both_barriers_and_private_registry_profile passed an unquoted Windows path to sp.check. The policy tokenizer treats an unquoted \ as an escape (stage_permissions.py:302), so the path was mangled. The helper path is now quoted with json.dumps, whose \\ the double-quote branch reads as \.
  • PowerShell installer only aggregates the Windows shards and has no cause of its own.

The Windows fixes are confirmed by reasoning and by Linux runs only. No Windows host was available here, so the pushed head's Windows shards decide them.

Verification (agent-reported)

Level Command Exit Observed
test python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_executors tests.test_stage_permissions tests.test_issue_review tests.test_run_cycle 0 573 tests OK
test python3 -m unittest discover -s tests 0 1635 tests OK
static python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
test python3 -m unittest 0 0 tests ran: default discovery from the root finds nothing, so this command proves nothing
  • Environment. Linux/WSL, with a per-dispatch TMPDIR. The tests set their own Git identity in their fixtures and do not rely on global Git config. Windows path behaviour was not exercised locally.
  • Fix-delta review. The base is 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 (trusted review receipt), confirmed as an ancestor of 8bfbba9 with git merge-base --is-ancestor. The delta is the fix commit. The delegated pass found no P0/P1 issue.
  • Security triage. It ran because the fixes touch sandbox network profiles. The change narrows network grants. Registry domains stay user-selected, as documented. No new risk was found.
  • Not run. Native codex sandbox/srt preparation still cannot run inside a stage, the same reservation the review recorded.

Checks of the pushed head (parallel policy, read once)

Head 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4: 0 passed, 0 failed, 1 pending.

Check State
Windows test shard (windows-4) pending (queued)

The other gates (Skills, manifests, and Bash installer, the other Windows shards, PowerShell installer) had not registered on this head when it was read. None of them is described as passed.

Residual risk

  • How issue_review reaches the code host from Codex is still a design question: a read-scoped credential, or host-side reads. Today it reports an environment blocker.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design.
ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-resolve-comments","status":"RESOLVED","issue_provider":"github","issue_id":"279","code_host":"github","change_request_id":"287","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/287","pr_number":287,"issue_number":279,"previous_head_sha":"4f1532a34b74984452a3b3e1d902cc61c2d4b0e8","head_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4","triage_run_id":"CCT-20261020-001","triaged_sha":"4f1532a34b74984452a3b3e1d902cc61c2d4b0e8","finding_outcomes":[{"id":"REV-001","disposition":"valid","status":"resolved"},{"id":"REV-002","disposition":"valid","status":"resolved"},{"id":"REV-003","disposition":"valid","status":"resolved"},{"id":"REV-004","disposition":"valid","status":"resolved"}],"resolved_findings":[{"id":"REV-001","status":"resolved","commit_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4"},{"id":"REV-002","status":"resolved","commit_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4"},{"id":"REV-003","status":"resolved","commit_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4"},{"id":"REV-004","status":"resolved","commit_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4"}],"unresolved_findings":[],"tests":{"ran":true,"passed":true,"conclusion":"verified_with_reservations","boundary":"required","evidence":[{"level":"test","command":"python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_executors tests.test_stage_permissions tests.test_issue_review tests.test_run_cycle","exit_code":0,"executed":573},{"level":"test","command":"python3 -m unittest discover -s tests","exit_code":0,"executed":1635},{"level":"static","command":"python3 scripts/validate-package.py","exit_code":0,"executed":null},{"level":"test","command":"python3 -m unittest","exit_code":0,"executed":0}]},"checks":{"head_sha":"8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4","passed":0,"failed":0,"pending":1,"items":[{"name":"Windows test shard (windows-4)","state":"pending"}]},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: REVIEW_PASSED_AWAITING_CI. Head 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 was rereviewed in full. All four previous findings are resolved and verified by execution, and there are no new findings. This is not an approval: one required check has failed, one is pending and one has not registered (see CI), and the cycle's CI gate decides.

What changed since the previous review

The previous review covered 4f1532a34b74984452a3b3e1d902cc61c2d4b0e8. Fix commit 8bfbba9 changes 7 files (+199/−27): scripts/executors.py, scripts/dependency_setup.py, docs/{dependency-preparation,host-permissions,routing}.md, tests/test_dependency_setup.py and tests/test_stage_dispatch.py.

I also reread the whole accumulated diff against origin/main: merge base bbd3149274f07591f30e1374d3188778e243bad6, 1687 lines (runtime-supplied file, line count confirmed, head matches).

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py:1167-1174, scripts/executors.py:1824-1858

Fixed. NativeAdapter.dispatch now adds REVIEW_SANDBOX_DOMAINS only when publishes is true. CodexAdapter.argv picks a code_cycle_publish_* profile from publishes alone, and picks code_cycle_registry_* only when registry domains are selected. With no domains it falls back to -s read-only/workspace-write, or to code_cycle_review_read for a review clone. A review clone that does get the registry profile still gets its clone and TMPDIR write rules, because the scratch rule in _dispatch_scratch is keyed on whichever profile is active.

Verified by execution: test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains covers 7 roles × active/inactive policy × with/without registries, and asserts that no code-host domain and no code_cycle_publish appear. test_codex_publishing_dispatch_keeps_code_host_and_registry_domains and test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route both pass too.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py:83-95 (accumulated diff sandbox_command)

Fixed. Codex read rules are kept only for tracked paths inside a writable output, or ancestors of one. :read-only covers everything else. Claude's srt file keeps the full denyWrite list.

Verified by execution: test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument uses 3,000 tracked files and asserts the argument stays under 16 KiB with no source paths in it, while a tracked .yarn file stays protected. test_codex_protects_tracked_ancestors_of_writable_outputs covers ancestors. Both pass.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py (DependencyPreparationDispatchTests), tests/test_dependency_setup.py

Fixed. test_preparation_role_gating_and_evidence_reach_each_native_prompt drives both adapters' real dispatch across 7 roles. It asserts prepare.assert_called_once_with(cwd, executor, binary, domains=…) for writing and review roles, assert_not_called for the others, the notice in the Codex final argument and the Claude -p prompt, and artifacts["dependency_preparation"]. test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent covers the incomplete path. The clean-clone test now goes through _isolated_review_dispatch → adapter.dispatch, asserts that prepare ran once on the clone path, and asserts the source checkout gained no node_modules. Removing the wiring in dispatch would fail all three. All pass.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md

Fixed in the documentation, as the review's first option proposed. All three docs now say the hook guards only direct Git, code-host and Docker invocations. They also say that selecting an interpreter, wrapper, code-running command or MCP integration trusts its nested operations and can bypass the publication boundary. A documentation finding is verified by reading; no behaviour changed.

New findings

None.

Security triage

The audit ran. .code-cycle.yml has no security_review.always_when rule, so the default triggers apply. The change touches sandbox network profiles, the stage command table and credential exposure during installs. The cc-security-review pass ran inline in this reviewer, not as a separately loaded delegate.

Result: the fix narrows the Codex network grant. Non-publishing Codex stages (issue review, security, bootstrap, local-only writers) no longer get a code-host route, and registry domains are the only domains a user choice can add. A Claude stage that selects registry domains now starts Claude Code's Bash sandbox with the code hosts plus those registries. Before this change, that stage had no Bash sandbox at all, so this is a narrowing too, and docs/host-permissions.md describes it. No new vulnerability was found.

Verification (executed in this rereview's clone)

Command Exit Observed
python3 -m unittest discover -s tests 1 1635 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran: discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_executors tests.test_stage_permissions tests.test_issue_review tests.test_run_cycle 1 573 tests; only the environmental test_executors failure below
python3 -m unittest -v on the 12 regression tests named above 0 12 tests OK

The environmental failures are the same ones the initial review recorded, in modules this PR does not change:

  • the 62 test_validate_package errors are all [Errno 13] Permission denied on sandbox-masked dotfiles during copytree;
  • test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout fails with "no temporary directory outside the dispatch checkout", because this sandbox has no writable temp parent outside its allowed paths.

Unverified

  • Native preparation through real codex sandbox and srt cannot run inside a review stage, and docs/dependency-preparation-campaign.md is still BLOCKED. That remains the open release-validation item for Keep development moving through routine sandbox and dependency setup #279.
  • Windows behaviour was not run locally, and the CI result for windows-2 (below) is still undiagnosed.

CI (parallel policy, read once, not waited on)

Head 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4:

Check State
Skills, manifests, and Bash installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-3) pass
Windows test shard (windows-2) fail
Windows test shard (windows-4) pending
PowerShell installer not registered on this head when read (missing)

3 passed, 1 failed, 1 pending, 1 missing. windows-2 is the shard that runs test_dependency_setup, and it failed on the previous head too. The fix for that test was reasoned out but never run on Windows. Its logs were not read in this stage. Under the parallel policy the cycle's CI gate, not this review, turns that failure into resolution work.

Residual risk

  • Codex issue_review now has no code-host route. It relies on host-supplied context or reports an environment_blocker, and how it should read the code host remains a design decision.
  • docs/dependency-preparation.md ("Default code-host domains are granted only to publishing stages…") sits in a Codex paragraph and is accurate for Codex only. Claude's registry sandbox also allows the code hosts, as docs/host-permissions.md states.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design.
  • The PR is still a draft.

Verdict: REVIEW_PASSED_AWAITING_CI. No blocking findings.

…hort paths

prepare() resolves the checkout, so on Windows runners the 8.3 temp path (RUNNER~1) expands to the long user name and the expected permission entries never matched. Resolve the fixture root the same way.

Refs #279
@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution summary — failed checks of 8bfbba9

Status: RESOLVED · new head aca7b76f4dce27b069f174302657ba493e454e95

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

This round only addresses the required checks that failed on the reviewed head 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4. Those failures are not review findings. The review findings below keep their published state and frozen dispositions, and this attempt makes no claim about them.

Failed checks on 8bfbba9

Check Diagnosis Action
Windows test shard (windows-2) Two tests in tests/test_dependency_setup.py failed: test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument and test_retries_transient_failure_records_head_logs_and_package_outputs. prepare() canonicalizes the checkout with Path(cwd).resolve(). On the Windows runner that turns the 8.3 temp path C:\Users\RUNNER~1\... into C:\Users\runneradmin\.... The fixture built its expected entries from the unresolved tempfile path, so they never matched. The production code is correct, and this change added the fixture, so the cause is within this change. Fixed in aca7b76: the fixture root is now resolved the same way prepare() resolves it.
PowerShell installer The aggregate gate "Require all Windows test shards to pass" failed only because windows-2 failed. It has no cause of its own. Fixed by the same commit.

Verification (agent-reported)

  • python3 -m unittest tests.test_dependency_setup: exit 0, 15 tests OK.
  • python3 -m unittest discover -s tests: exit 0, 1635 tests OK.
  • python3 scripts/validate-package.py: exit 0, VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned.
  • Boundary: the failure only happens on Windows, where the temp directory uses an 8.3 short name. The local run was on Linux, where resolve() does not change the temp path, so the run passing proves no regression but cannot reproduce the original failure. The Windows CI shard on the new head is the real check. Like CI, the local run does not depend on the global Git identity, because the fixture commits with an explicit -c user.name/user.email.

Post-change review

  • Delta base: 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4, the latest trusted rereview head. It is an ancestor of aca7b76, so the fix delta was reviewed: a one-line change to the fixture plus a comment. No findings.
  • Security triage: only a test changed, with no sensitive surface, so no security audit was needed.

Checks of the pushed head aca7b76f4dce27b069f174302657ba493e454e95

The checks were read once, as the parallel CI policy requires. statusCheckRollup was still empty, so all 6 expected checks are pending (Skills, manifests, and Bash installer, Windows test shard (windows-1..4), PowerShell installer). None of them has passed yet.

Findings (unchanged by this attempt)

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: REVIEW_PASSED_AWAITING_CI. Head aca7b76f4dce27b069f174302657ba493e454e95 was rereviewed in full. All four previous findings remain resolved, and I re-verified them by execution on this head. There are no new findings. This is not an approval: the required check Skills, manifests, and Bash installer failed on this head (see CI), and the cycle's CI gate decides.

What changed since the previous review

The previous rereview (CCR-20261020-002) covered 8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4. The only new commit is aca7b76, which touches tests/test_dependency_setup.py (+2/−1). In SetupTests.setUp, the fixture root is now Path(self.temp.name).resolve() / "source", so it matches the root that prepare() canonicalizes with Path(cwd).resolve(). On a Windows runner, an 8.3 temp path such as RUNNER~1 would otherwise differ from the resolved path. The commit adds a comment and makes no production change. Every assertion that compares against self.root (the apps/web/node_modules write rule and the .yarn/tracked-plugin.cjs read rule) now uses the resolved root. self.evidence stays unresolved, but nothing compares it against the argv, so that is consistent.

I also reread the whole accumulated diff against origin/main: merge base bbd3149274f07591f30e1374d3188778e243bad6, 1688 lines (runtime-supplied file). The line count is confirmed and the PR head matches. The file's SHA-256 was not recomputed, because sha256sum is not in this stage's command table.

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py:1167-1174, scripts/executors.py:1824-1843

The fix is unchanged on this head. Default code-host domains are added only when publishes is true. Non-publishing stages get code_cycle_registry_* only when registry domains are selected; otherwise they keep the network-less path. Re-verified by execution on this head: test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains, test_codex_publishing_dispatch_keeps_code_host_and_registry_domains and test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route pass.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py (sandbox_command)

The fix is unchanged. Codex read rules are kept only for tracked paths inside writable outputs, or ancestors of them. Re-verified on this head: test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument (3,000 tracked files, argument under 16 KiB) and test_codex_protects_tracked_ancestors_of_writable_outputs pass.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py (DependencyPreparationDispatchTests), tests/test_dependency_setup.py

The fix is unchanged. Re-verified on this head: test_preparation_role_gating_and_evidence_reach_each_native_prompt, test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent and test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies pass.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md

Unchanged and still accurate. The three docs say the hook guards only direct Git, code-host and Docker invocations, and that a selected interpreter, wrapper, code-running command or MCP integration trusts its nested operations. This was verified by reading the accumulated diff.

New findings

None.

Security triage

The audit ran. .code-cycle.yml has no security_review.always_when rule, so the default triggers apply. The accumulated change touches sandbox network profiles, the stage command table and credential exposure during installs. The cc-security-review pass ran inline in this reviewer, not as a separately loaded delegate. The new delta is a test-fixture change with no sensitive surface. In the accumulated diff, network grants stay narrowed as recorded in CCR-20261020-002, and no new vulnerability was found.

Verification (executed in this rereview's clone, Linux/WSL)

Command Exit Observed
python3 -m unittest discover -s tests 1 1635 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran: discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_stage_permissions tests.test_issue_review tests.test_run_cycle 0 388 tests OK
python3 -m unittest -v on the 12 regression tests for REV-001…REV-003 and the two earlier Windows CI tests 0 12 tests OK

The environmental failures are the same ones the two previous reviews recorded, in modules this PR does not change:

  • all 62 errors are in test_validate_package, and each is [Errno 13] Permission denied (62 occurrences) on sandbox-masked dotfiles during copytree;
  • the one failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout, because this sandbox has no writable temp parent outside its allowed paths.

Unverified

  • The Windows 8.3 short-path fix cannot be reproduced on Linux, where resolve() leaves the temp path unchanged. The Windows CI result below is the real check, and windows-2 passed on this head.
  • Native preparation through real codex sandbox and srt cannot run inside a review stage, and docs/dependency-preparation-campaign.md is still BLOCKED. This remains the open release-validation item for Keep development moving through routine sandbox and dependency setup #279.
  • Two commands were denied by this stage's table and no workaround was attempted: gh api repos/datacas/code-cycle-toolkit/issues/287/comments (comments were read with gh pr view --json comments instead) and sha256sum on the diff file (the hash was not recomputed).

CI (parallel policy, read once, not waited on)

Head aca7b76f4dce27b069f174302657ba493e454e95:

Check State
Skills, manifests, and Bash installer fail
PowerShell installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-2) pass
Windows test shard (windows-3) pass
Windows test shard (windows-4) pass

5 passed, 1 failed, 0 pending.

  • The Windows shards that failed on earlier heads (windows-2, windows-4) and the PowerShell installer aggregate now pass.
  • Skills, manifests, and Bash installer passed on 8bfbba9 and fails on this head, although the only change between the two heads is the test-fixture line above, and the same module passes locally on Linux. Its logs were not read in this stage, so the cause is undiagnosed.
  • Under the parallel policy, the cycle's CI gate, not this review, turns that failure into resolution work.

Residual risk

  • Codex issue_review has no code-host route. It relies on host-supplied context or reports an environment_blocker. How it should read the code host remains a design decision.
  • docs/dependency-preparation.md ("Default code-host domains are granted only to publishing stages…") holds for Codex only. Claude's registry sandbox also allows the code hosts, as docs/host-permissions.md states.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design.
  • The PR is still a draft.

Verdict: REVIEW_PASSED_AWAITING_CI. No blocking findings.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolve: failed check on aca7b76 — infrastructure, no code change

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

Functional status: PARTIALLY_RESOLVED. No review finding is open. One required check failed for a cause outside this change, so the head stays at aca7b76f4dce27b069f174302657ba493e454e95.

Failed check diagnosis

Skills, manifests, and Bash installer (job 118574294794) — infrastructure: the self-hosted Linux runner's disk is full.

  • The suite ran 1635 tests and 1634 passed. The single error was test_validate_package.ValidatePackageTests.test_rejects_a_description_that_is_not_valid_yaml (fragment read-only #1 rule), raised by shutil.copytree → os.makedirs:
    OSError: [Errno 28] No space left on device: '/tmp/tmppkurw113/package'
  • That test, and copy_package in tests/test_validate_package.py, are unchanged by this PR. The failure is a failed mkdir in the runner's /tmp, not an assertion.
  • On 8bfbba9, the same Linux job passed. The only commit since then (aca7b76) changes one line in tests/test_dependency_setup.py (Path(...).resolve() for the fixture root).
  • This change's temporary-directory use doesn't leak. tests/test_dependency_setup.py and tests/native_dependency_campaign.py use TemporaryDirectory with cleanup. dependency_setup.prepare scratch space is a TemporaryDirectory, and its evidence goes under evidence_root or ~/.local/state, not /tmp. It returns not_required before creating anything when the checkout has no package manifests.
  • Action needed (human/infra): free space on the self-hosted runner (/home/github-runner/..., /tmp), then re-run the job. Nothing in this change can fix it.

The earlier branch failures (4f1532a, 8bfbba9) were in-scope Windows RUNNER~1 short-path assertions. aca7b76 fixed them, and all four Windows shards and the PowerShell installer pass on it.

Findings (unchanged by this round; dispositions frozen)

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py — resolved in 8bfbba9; rereview CCR-20261020-003 confirmed on aca7b76.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py — resolved in 8bfbba9; confirmed on aca7b76.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_dependency_setup.py — resolved in 8bfbba9; confirmed on aca7b76.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/ — resolved in 8bfbba9; confirmed on aca7b76.

Verification (agent-reported, local, on aca7b76)

Level Command Exit Result
test python3 -m unittest discover -s tests 0 Ran 1635 tests — OK
static python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned

The local run uses WSL2 Linux with its own /tmp and disk. It shares no state with the self-hosted CI runner, so it can't reproduce that runner's disk exhaustion. Fix-delta review: no delta (no commit since delta base aca7b76), so there was no new diff to review. The sensitivity triage is unchanged.

Checks on aca7b76f4dce27b069f174302657ba493e454e95 (read once, not pushed)

Check State
Skills, manifests, and Bash installer fail (infrastructure: ENOSPC)
PowerShell installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-2) pass
Windows test shard (windows-3) pass
Windows test shard (windows-4) pass

Residual risk

None in the code. The cycle shouldn't rereview this head again; it needs a re-run of the failed job once the runner has disk space.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-resolve-comments","status":"PARTIALLY_RESOLVED","issue_provider":"github","issue_id":"279","code_host":"github","change_request_id":"287","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/287","pr_number":287,"issue_number":279,"previous_head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","triage_run_id":"CCT-20261020-003","triaged_sha":"aca7b76f4dce27b069f174302657ba493e454e95","finding_outcomes":[],"resolved_findings":[],"unresolved_findings":[],"tests":{"ran":true,"passed":true,"conclusion":"verified","boundary":"not_required","evidence":[{"level":"test","command":"python3 -m unittest discover -s tests","exit_code":0,"executed":1635},{"level":"static","command":"python3 scripts/validate-package.py","exit_code":0,"executed":null}]},"checks":{"head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","passed":5,"failed":1,"pending":0,"items":[{"name":"Skills, manifests, and Bash installer","state":"fail"},{"name":"PowerShell installer","state":"pass"},{"name":"Windows test shard (windows-1)","state":"pass"},{"name":"Windows test shard (windows-2)","state":"pass"},{"name":"Windows test shard (windows-3)","state":"pass"},{"name":"Windows test shard (windows-4)","state":"pass"}]},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: REVIEW_PASSED_AWAITING_CI. I rereviewed head aca7b76f4dce27b069f174302657ba493e454e95 in full. All four previous findings are still resolved, and I verified them again by execution on this head. There are no new findings. This is not an approval: the required check Skills, manifests, and Bash installer is running again on this head and has not passed yet (see CI). The cycle's CI gate decides.

What changed since the previous review

The code has not changed. The previous rereview (CCR-20261020-003) covered this same head, aca7b76. Since then the only activity was the resolve round CCT-20261020-003. It diagnosed the failed Linux job as runner disk exhaustion (ENOSPC in /tmp during copytree in the unchanged test_validate_package), made no commit, and that job has since been re-run.

I reread the whole accumulated diff against origin/main: merge base bbd3149274f07591f30e1374d3188778e243bad6, 1688 lines. This is the runtime-supplied file; I confirmed the line count, and the PR head matches. It covers scripts/{dependency_setup,user_choices,executors,stage_permissions,run_cycle,issue_review,cycle}.py, the manifests, docs and tests.

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py (NativeAdapter.dispatch network domains; CodexAdapter.argv profile selection)

Still resolved:

  • Default code-host domains are added only when publishes is true.
  • A non-publishing stage gets code_cycle_registry_* only when registry domains are selected.
  • An empty domain tuple keeps the network-less -s read-only/workspace-write path, or code_cycle_review_read for a review clone.

Verified by execution on this head; all pass:

  • test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains
  • test_codex_publishing_dispatch_keeps_code_host_and_registry_domains
  • test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py (sandbox_command)

Still resolved. Codex read rules are kept only for protected paths inside a writable output, or ancestors of one. :read-only covers the rest.

Verified by execution on this head; both pass:

  • test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument (3,000 tracked files; the argument stays under 16 KiB)
  • test_codex_protects_tracked_ancestors_of_writable_outputs

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py (DependencyPreparationDispatchTests), tests/test_dependency_setup.py

Still resolved. Verified by execution on this head; all pass:

  • test_preparation_role_gating_and_evidence_reach_each_native_prompt
  • test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent
  • test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies, which goes through _isolated_review_dispatch → adapter.dispatch

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md

Still resolved and accurate. I checked this by reading the accumulated diff. All three docs say:

  • the hook guards only direct Git, code-host and Docker invocations;
  • selecting an interpreter, wrapper, code-running command or MCP integration trusts its nested operations.

New findings

None.

Security triage

The audit ran. .code-cycle.yml has no security_review.always_when rule, so the default triggers apply. The accumulated change touches sandbox network profiles, the stage command table, and credential exposure during installs. The cc-security-review pass ran inline in this reviewer, not as a separately loaded delegate.

No code changed since CCR-20261020-003. The accumulated result stands; no new vulnerability was found:

  • Codex network grants are narrowed to publishing stages, plus user-selected registries.
  • Preparation drops credential environment variables and refuses symlinked outputs.
  • The review clone does not load the PR's .code-cycle.yml.
  • The Git/gh/Docker guard runs before user choices.

Verification (executed in this rereview's clone, Linux/WSL)

Command Exit Observed
python3 -m unittest discover -s tests 1 1635 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran: discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_stage_permissions tests.test_issue_review tests.test_run_cycle 0 388 tests OK
python3 -m unittest -v on the 12 regression tests for REV-001…REV-003 and the earlier Windows CI tests 0 12 tests OK

The environmental failures are the same ones the three previous reviews recorded, and they are in modules this PR does not change:

  • All 62 errors are in test_validate_package, and the log has 62 [Errno 13] Permission denied lines. They come from sandbox-masked dotfiles during copytree.
  • The one failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout ("no temporary directory outside the dispatch checkout"). This sandbox has no writable temp parent outside its allowed paths.

Unverified

  • Native preparation through real codex sandbox and srt cannot run inside a review stage, and docs/dependency-preparation-campaign.md is still BLOCKED. This remains the open release-validation item for Keep development moving through routine sandbox and dependency setup #279.
  • The ENOSPC diagnosis of the earlier Linux job failure comes from the resolve stage; I did not read those logs here. The re-run in progress decides it.

CI (parallel policy, read once, not waited on)

Head aca7b76f4dce27b069f174302657ba493e454e95:

Check State
Skills, manifests, and Bash installer pending (re-run in progress, started 11:14:59Z)
PowerShell installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-2) pass
Windows test shard (windows-3) pass
Windows test shard (windows-4) pass

5 passed, 0 failed, 1 pending. Under the parallel policy, the cycle's CI gate waits for the Linux job and decides.

Residual risk

  • Codex issue_review has no code-host route. It relies on host-supplied context, or it reports an environment_blocker. How it should read the code host is still a design decision.
  • A Claude stage that selects registry_domains now runs Bash under Claude Code's sandbox with failIfUnavailable. On a host without the sandbox prerequisites, that stage's Bash fails rather than running unsandboxed. This is opt-in and documented in docs/host-permissions.md.
  • docs/dependency-preparation.md ("Default code-host domains are granted only to publishing stages…") holds for Codex only. Claude's registry sandbox also allows the code hosts.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design.
  • The PR is still a draft.

Verdict: REVIEW_PASSED_AWAITING_CI. No blocking findings.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-rereview","status":"REVIEW_PASSED_AWAITING_CI","issue_provider":"github","issue_id":"279","code_host":"github","change_request_id":"287","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/287","pr_number":287,"issue_number":279,"previous_reviewed_head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","reviewed_head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","review_run_id":"CCR-20261020-004","reviewer":{"profile":"senior_reviewer","provider":"anthropic","model_requested":"claude-opus-5-5","model_resolved":null,"effort":"high"},"verified_findings":[{"id":"REV-001","severity":"high","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-002","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-003","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-004","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"}],"new_findings":[],"blocking_findings":[],"checks":{"head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","passed":5,"failed":0,"pending":1},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: CHANGES_REQUESTED. I rereviewed head aca7b76f4dce27b069f174302657ba493e454e95 in full and verified the recovered attempt attempt-2c89274147014b6d92a1f5b6542dcfcb (CCR-20261020-004).

  • REV-001…REV-004 are still resolved. I checked them again by execution on this head, and by reading the diff for REV-004.
  • All six CI checks now pass on this head.
  • One new blocking finding, REV-005: two acceptance criteria of Keep development moving through routine sandbox and dependency setup #279 need the native Claude/Codex campaign, and it has not passed. The PR's own campaign record says BLOCKED, and I got the same result when I re-ran it here. The earlier rereviews listed this under Unverified. This review gates on it, because an approval would claim that Keep development moving through routine sandbox and dependency setup #279's acceptance criteria are met. A person has to close it with an authorized host executor; a code change cannot.

What changed since the previous review

The code has not changed: CCR-20261020-004 reviewed this same head. Since then, the re-run of Skills, manifests, and Bash installer finished with success at 2026-10-20T11:18:51Z.

I reread the whole accumulated diff against origin/main:

  • merge base bbd3149274f07591f30e1374d3188778e243bad6, 1688 lines;
  • this is the runtime-supplied file; I confirmed its line count, and the PR head matches;
  • I could not recompute its SHA-256 here, because sha256sum is not in this stage's command table. Head and line count match.

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py (NativeAdapter.dispatch network domains; CodexAdapter.argv profile selection)

Still resolved:

  • REVIEW_SANDBOX_DOMAINS is added only when publishes is true.
  • A non-publishing stage gets code_cycle_registry_* only when registry domains are selected.
  • No domains keeps the network-less path, or code_cycle_review_read for a review clone.

Verified on this head; all pass:

  • test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains
  • test_codex_publishing_dispatch_keeps_code_host_and_registry_domains
  • test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py (sandbox_command)

Still resolved. read rules are kept only for protected paths inside a writable output, or ancestors of one. :read-only covers the rest. The native-campaign argv I captured on this head confirms it: the filesystem argument lists only the six writable outputs.

Verified on this head; both pass:

  • test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument
  • test_codex_protects_tracked_ancestors_of_writable_outputs

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py (DependencyPreparationDispatchTests), tests/test_dependency_setup.py

Still resolved. Verified on this head; all pass:

  • test_preparation_role_gating_and_evidence_reach_each_native_prompt
  • test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent
  • test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies, which goes through _isolated_review_dispatch → adapter.dispatch

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md

Still resolved; I checked it by reading the accumulated diff. All three docs say:

  • the hook guards only direct Git, code-host and Docker invocations;
  • selecting an interpreter, wrapper, code-running command or MCP integration trusts its nested operations.

New findings

[REV-005] · medium · open · - · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

docs/dependency-preparation-campaign.md (line 3, Status: **BLOCKED**), tests/native_dependency_campaign.py

#279's acceptance criteria and its recorded decision Q-004 require:

  • reproducing a dependency-requiring review in a fresh clone under the actual native Claude and Codex sandbox paths, cold case included;
  • dependency setup and configured verification running under both native executors;
  • one documented manual campaign covering both executors, with commands, logs, exit codes and HEAD.

The PR's campaign record shows neither executor installed or verified anything, and the PR body says the same ("draft, native acceptance validation incomplete").

I re-ran python3 -m unittest tests.native_dependency_campaign on this head. Exit 1; 2 tests, 2 failures:

  • claude: package manager version failed with exit None: Claude dependency preparation needs the installed srt sandbox runtime
  • codex: codex sandbox --permission-profile code_cycle_prepare … -- npm --version exit 1, with bwrap: No permissions to creating new namespace, likely because the kernel does not allow non-privileged user namespaces.

That is this review sandbox's restriction: a nested bwrap and no srt. It does not show a code defect. What it shows is that the required evidence does not exist yet.

Resolution: run the campaign from a host executor where native sandboxes work and srt is installed. Attach the passing install and verification logs, exit statuses and the exact HEAD, and update docs/dependency-preparation-campaign.md. If the campaign fails there, fix the defect it exposes. If the maintainer decides to defer this criterion, record that decision on #279; this review does not waive it.

Security triage

The audit ran. .code-cycle.yml defines no security_review.always_when rule, so the default triggers apply: the change touches sandbox network profiles, the stage command table, and install-time credential exposure. The cc-security-review pass ran inline in this reviewer, not as a separately loaded delegate.

The accumulated result stands; no new vulnerability was found:

  • Codex network grants are limited to publishing stages, plus user-selected registry hosts.
  • Preparation drops credential environment variables, isolates HOME/TMPDIR in scratch, and refuses symlinked or escaping outputs.
  • user_choices rejects shell operators, redirections, wildcard registries and non-MCP integration patterns.
  • The direct git/gh/docker guard runs before user choices.
  • The review clone does not load the PR's .code-cycle.yml.

Verification (executed in this rereview's clone, Linux/WSL)

Command Exit Observed
python3 -m unittest discover -s tests 1 1635 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran: discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest -v on the 8 REV-001…REV-003 regression tests 0 8 tests OK
python3 -m unittest tests.native_dependency_campaign 1 2 failures (see REV-005); no native install or lookup succeeded

The suite failures are the same environmental ones the four previous reviews recorded, and they are in modules this PR does not change:

  • All 62 errors are in test_validate_package, and the log has 62 [Errno 13] Permission denied lines. They come from sandbox-masked dotfiles during copytree.
  • The one failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout. This sandbox has no writable temp parent outside its allowed paths.

CI's Linux job runs the same suite, and it passed on this head.

Unverified

  • Native preparation through real codex sandbox and srt (REV-005).
  • The SHA-256 of the supplied diff file (sha256sum is not in this stage's table). Head SHA and line count match.

CI (parallel policy, read once, not waited on)

Head aca7b76f4dce27b069f174302657ba493e454e95:

Check State
Skills, manifests, and Bash installer pass (re-run, completed 11:18:51Z)
PowerShell installer pass
Windows test shard (windows-1) pass
Windows test shard (windows-2) pass
Windows test shard (windows-3) pass
Windows test shard (windows-4) pass

6 passed, 0 failed, 0 pending.

Residual risk

  • Codex issue_review has no code-host route: it needs host-supplied context, or it reports an environment_blocker.
  • A Claude stage with registry_domains runs Bash under failIfUnavailable. It fails closed on hosts without the sandbox prerequisites. This is documented.
  • "Default code-host domains are granted only to publishing stages" holds for Codex only. Claude's registry sandbox also allows the code hosts.
  • Lifecycle-script builds stay scripts_disabled/incomplete by design.
  • The PR is still a draft.

Verdict: CHANGES_REQUESTED. Blocking: REV-005.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-rereview","status":"CHANGES_REQUESTED","issue_provider":"github","issue_id":"279","code_host":"github","change_request_id":"287","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/287","pr_number":287,"issue_number":279,"previous_reviewed_head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","reviewed_head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","review_run_id":"CCR-20261020-005","reviewer":{"profile":"senior_reviewer","provider":"anthropic","model_requested":"claude-opus-5-5","model_resolved":null,"effort":"high"},"verified_findings":[{"id":"REV-001","severity":"high","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-002","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-003","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-004","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"}],"new_findings":[{"id":"REV-005","severity":"medium","status":"open","disposition":"-","blocks_approval":true,"path":"docs/dependency-preparation-campaign.md","line":3}],"blocking_findings":["REV-005"],"checks":{"head_sha":"aca7b76f4dce27b069f174302657ba493e454e95","passed":6,"failed":0,"pending":0},"blocking":false}
END_ORCHESTRATION_RESULT

…ites

Codex grants writes only to existing paths, so npm ci could not create a missing node_modules under the read-only checkout (ENOENT). Create package-local outputs after the escape checks and before the install, and require a non-dot entry so an empty pre-created directory or a sandbox placeholder never counts as an install. Record the native campaign reruns for REV-005; the Codex EBUSY on its protected .agents placeholder and the absent srt runtime remain open.

Refs #279
@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

Status: BLOCKED. REV-005 is still open. Running the native campaign from this Claude stage exposed a real Codex preparation defect, which is now fixed and pushed in cffd87a84d7798c5414c19fff7ebb9a397c9fcea. The rerun then hit two more obstacles, and both need a person:

  • a second Codex defect, which needs a design decision;
  • the srt runtime, which is missing on this host.

Findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged in this round; the full suite passes on the new head.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. Unchanged in this round. test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument still passes.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. Unchanged in this round; those tests still pass.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

Docs unchanged in this round.

[REV-005] · medium · open · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

scripts/dependency_setup.py, tests/test_dependency_setup.py, docs/dependency-preparation-campaign.md

Triage: valid (judged against aca7b76). Q-004 on #279 requires a documented campaign under both native executors, and the campaign record says BLOCKED.

What this round found. This host's Claude stage can start codex sandbox, so I ran python3 -m unittest tests.native_dependency_campaign here.

  1. Defect fixed. Codex's npm --version exited 0, then npm ci exited 254 with ENOENT … mkdir '<fixture>/node_modules'. A write grant on a path that does not exist stays under the read-only checkout, so the package manager cannot create it.
    • Fix (cffd87a): prepare now creates each package's node_modules on the host before the install, after the existing symlink and escape checks. It does the same for .yarn, Yarn only.
    • The required-outputs check now needs a non-dot entry. An empty pre-created directory or a sandbox placeholder never counts as an install.
    • Regression tests: test_missing_outputs_exist_before_the_native_sandbox_grants_writes and test_empty_precreated_output_is_not_a_successful_install.
  2. Still failing — Codex. On rerun, npm ci exited 240 with EBUSY: resource busy or locked, rmdir '<fixture>/apps/web/node_modules/.agents'. Codex mounts a protected .agents placeholder inside every writable root, and npm ci empties node_modules before installing. It cannot remove a mount point. Fixing this needs a design choice; see below.
  3. Still failing — Claude. srt is absent on this host: Claude dependency preparation needs the installed srt sandbox runtime, exit null. The stage's command table also denies command -v srt, so I did not probe the host any further.

docs/dependency-preparation-campaign.md now records all three runs, with commands, exit codes and fixture HEADs. Its status stays BLOCKED.

Decisions needed before REV-005 can close:

Verification (agent-reported, Linux/WSL, Claude stage)

Command Exit Observed
python3 -m unittest tests.test_dependency_setup 0 17 tests OK, 2 of them new
python3 -m unittest discover -s tests 0 1637 tests OK
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran; root discovery finds nothing, so this proves nothing
python3 -m unittest tests.native_dependency_campaign (on the final code) 1 2 failures: Codex EBUSY (exit 240), Claude without srt (exit null)

Environment assumptions:

  • Shared with CI: the test fixtures set their own Git identity.
  • Not shared with CI: real codex sandbox, and registry access to registry.npmjs.org. Only the native campaign uses them, and it is outside test_*.py discovery.

Post-change review

  • Fix-delta review. I reviewed it inline against delta base aca7b76f4dce27b069f174302657ba493e454e95, the latest trusted rereview receipt. It is an ancestor of cffd87a.
    • One issue found and fixed before the commit: a Codex .agents placeholder could have made an empty node_modules look populated.
    • No other findings.
  • Security triage. The change touches host-side filesystem writes in the preparation path, so the default triggers apply.
    • Directories are created only for output paths that already passed the symlink and in-checkout escape checks.
    • The only sandboxed command between those checks and mkdir is the manager's --version. The output paths do not exist at that point, and their parent is read-only.
    • No new network, credential or publication surface. No vulnerability found.

CI (parallel policy, read once, not waited on)

Head cffd87a84d7798c5414c19fff7ebb9a397c9fcea: no check runs were registered yet when I read them right after the push. 0 passed, 0 failed, 0 pending. The cycle's CI gate covers this head.

Residual risk

  • If REV-005 is fixed by staging the install, the pnpm metadata in a moved tree still needs native validation.
  • Yarn PnP files (.pnp.cjs, .pnp.loader.mjs) are not pre-created, so a Codex Yarn-PnP install fails honestly rather than succeeding.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Owner decisions for the open blockers of the last resolution (REV-005), recorded 2026-10-20. They answer the two questions that resolution listed; nothing else about scope changed.

  1. Codex npm ci fails with EBUSY … rmdir '<fixture>/apps/web/node_modules/.agents'. Decision: investigate whether Codex offers a permission option that stops it placing the .agents placeholder inside the writable output roots, and use it if it exists. Record the options examined and the outcome in docs/dependency-preparation-campaign.md. Only when no such option exists, fall back to the scratch-copy install (frozen install in a writable copy of the manifests and lockfile inside the sandbox, then move the finished node_modules trees into the checkout on the host). Do not defer npm preparation under Codex.
  2. Claude srt was missing on the host. It is now installed globally (@anthropic-ai/sandbox-runtime 0.0.81, srt on the PATH). Rerun the Claude half of the campaign and record commands, exit codes and the verified HEAD.

…ck npm ci

Codex mounts protected .agents/.codex/.git placeholders inside every writable root, and npm ci failed with EBUSY emptying a writable node_modules. The installed CLI offers no option to suppress them, so preparation now installs in a scratch copy of the lock root's tracked files, with only scratch and the download cache writable, and moves finished outputs into the checkout on the host. A failed install leaves the checkout untouched; tracked Yarn files are never overwritten.

The native campaign now passes for Codex; Claude still needs rg on the host for srt.

Refs #279
@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCT-20261020-005] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:cffd87a84d7798c5414c19fff7ebb9a397c9fcea · schema:2

Status: BLOCKED. I applied both owner decisions from 2026-10-20.

  • Codex half now passes. The installed CLI has no option to suppress the .agents placeholder, so preparation uses the owner's fallback, a scratch-copy install. It is pushed in def7bdb33c0c405c2689168da571f3044b2633d3. In the native campaign, the cold npm ci and the dependency lookup both exit 0 under the real codex sandbox.
  • Claude half is still blocked. srt is installed now, but it refuses to start: Error: Sandbox dependencies not available: ripgrep (rg) not found.
  • REV-005 stays open until someone installs rg on the host and the Claude half is rerun.

Findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged in this round; the full suite passes on the new head.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. Still resolved, and the margin is now larger. The checkout no longer gets write grants, so the only read rules left are the staged lockfile and manifests. test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument passes, updated for the new rules.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. Unchanged; test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies passes with the staged install.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

Docs unchanged in this round.

[REV-005] · medium · open · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

scripts/dependency_setup.py, tests/test_dependency_setup.py, docs/dependency-preparation.md, docs/dependency-preparation-campaign.md

The disposition stays as previously triaged (valid, judged against aca7b76). Triage for this round ran against cffd87a.

Owner decision 1: look for a Codex option first. I examined these options and recorded them in docs/dependency-preparation-campaign.md:

Option Outcome
A config key that disables or renames the protected names None in the installed CLI. .agents and .codex appear only as a constant beside the permission-profile code. The filesystem entry schema has access, missing_path_behavior, glob_scan_max_depth and entries.
missing_path_behavior Covers an entry's own missing path, not protected children.
A write entry on <output>/.agents It would be another bind mount inside the tree npm ci empties, so EBUSY would remain.
Granting the lock root instead Makes the checkout writable and brings back the per-file argv limit from REV-002. Rejected.

I could not consult the official Codex docs: this stage denied Context7, web fetch, and a direct codex command. The installed binary is authoritative for the version in use.

The fallback I implemented (def7bdb):

  • prepare copies the lock root's tracked files, plus any untracked manifests, into scratch, and runs the frozen install there.
  • The sandbox can write only scratch and the download cache. The staged lockfile and manifests stay read.
  • The checkout and .git are never writable, so no placeholder lands in a checkout output.
  • After a successful install and output check, the host re-checks the output paths for symlinks and escape. It then replaces each package's node_modules with the finished tree; links are moved, never followed.
  • Yarn: only untracked .pnp.cjs, .pnp.loader.mjs and untracked .yarn entries are published. Tracked releases and plugins are never overwritten.
  • A failed install leaves the checkout's outputs untouched.
  • The host-side node_modules pre-creation from cffd87a is superseded.

New and updated regression tests:

  • test_install_runs_in_a_scratch_copy_and_replaces_checkout_outputs
  • test_failed_install_leaves_checkout_outputs_untouched
  • test_yarn_publishes_only_untracked_generated_outputs
  • test_placeholder_only_output_is_not_a_successful_install
  • In test_retries_transient_failure_records_head_logs_and_package_outputs, no write rule and no install cwd may lie in the checkout.

Owner decision 2: rerun the Claude half with srt. Run 4 is recorded with commands, exit codes and fixture HEADs.

  • Codex (fixture HEAD bd8dca8a0b41c4d3a61f8ba8d1715fe96b302f7f): passed.
    • npm --version exited 0 (10.9.8).
    • npm ci --ignore-scripts … exited 0 (added 2 packages); preparation status prepared.
    • The in-sandbox node -e "require('is-number')(42)" ran without network and exited 0.
    • Lockfile and HEAD unchanged.
  • Claude (fixture HEAD db25a84e6dfc4a9f3442d45f21048c536e22abec): not run.
    • srt --settings … "npm --version" exited 1 with Error: Sandbox dependencies not available: ripgrep (rg) not found.
    • rg is a host prerequisite of srt. Installing it is outside this stage's authority.
    • docs/dependency-preparation.md now states that requirement.

Decision needed to close REV-005: install rg (ripgrep) on the host PATH, then rerun python3 -m unittest tests.native_dependency_campaign from a stage, or record a deferral of the Claude half on #279.

Verification (agent-reported, Linux/WSL, Claude stage)

Command Exit Observed
python3 -m unittest tests.test_dependency_setup 0 19 tests OK
python3 -m unittest tests.native_dependency_campaign (final code) 1 2 tests: Codex passed; Claude failed, ripgrep (rg) not found
python3 -m unittest discover -s tests 0 1639 tests OK
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran; root discovery finds nothing, so this proves nothing

Environment assumptions:

  • Shared with CI: the fixtures set their own Git identity.
  • Not shared with CI: the real codex sandbox and srt, and registry access. Only the native campaign uses them, and it sits outside test_*.py discovery.

Post-change review

  • Fix-delta review, inline against delta base aca7b76f4dce27b069f174302657ba493e454e95 (the latest trusted rereview receipt; an ancestor of def7bdb). No findings.
  • Security triage. The default triggers apply: sandbox filesystem grants and host-side writes.
    • The sandbox's write surface shrank from checkout outputs to scratch and cache only.
    • Host writes go only to output paths re-checked for symlinks and in-checkout escape just before the move. rmtree and move do not follow links, and nothing produced by the sandbox runs on the host.
    • No new network, credential or publication surface. No vulnerability found.

CI (parallel policy, read once, not waited on)

Head def7bdb33c0c405c2689168da571f3044b2633d3: no check runs were registered when I read them right after the push. 0 passed, 0 failed, 0 pending.

Residual risk

  • pnpm and Yarn have not been run under a native sandbox; only npm has. A manager that writes absolute paths into its outputs would point at the deleted scratch copy. pnpm and Yarn PnP normally write relative paths.
  • Staging copies every tracked file under the lock root once per preparation, which costs time on very large monorepos.
  • A file: dependency outside the lock root is not staged, so its install fails visibly rather than silently.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Owner follow-up for REV-005, recorded 2026-10-20: rg (ripgrep 15.2.0, official release, checksum verified) is now installed on the host at ~/.local/bin/rg, which is on the PATH, and srt starts. Rerun the Claude half of the native campaign and record commands, exit codes and fixture HEAD in docs/dependency-preparation-campaign.md. The Codex half already passed on def7bdb.

srt shell-quotes each positional argument, so the pre-joined string ran as one word (exit 127), and its own --version would shadow npm's. Record native campaign run 5: both Claude (srt) and Codex pass the cold install and the sandboxed dependency lookup.

Refs #279
@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCT-20261020-005] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:cffd87a84d7798c5414c19fff7ebb9a397c9fcea · schema:2

[CCT-20261020-006] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:def7bdb33c0c405c2689168da571f3044b2633d3 · schema:2

Status: RESOLVED. The native campaign now passes for both executors, so REV-005 is resolved. Fix commit: bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0.

After the owner installed rg, srt started. The rerun then exposed a real defect in how preparation calls srt. This round fixes that defect and records run 5.

Findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged in this round; the full suite passes on the new head.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. The Codex argv is unchanged in this round. test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument passes.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. Unchanged; the full suite passes.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

Docs unchanged in this round.

[REV-005] · medium · resolved · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

Files: scripts/dependency_setup.py, tests/test_dependency_setup.py, docs/dependency-preparation-campaign.md.

The disposition stays as previously triaged: valid, judged against aca7b76. Triage for this round ran against def7bdb.

Defect found by the native rerun, on def7bdb.

  • srt --settings <scratch>/sandbox.json "npm --version" exited 127 with /usr/bin/bash: line 1: npm --version: command not found.
  • Cause: the installed srt (@anthropic-ai/sandbox-runtime 0.0.81) shell-quotes each positional argument itself (quote(commandArgs) in dist/cli.js). The command that preparation had already joined with shlex.join therefore ran as one word.
  • Passing the arguments separately is not enough on its own. srt registers its own --version, so srt … npm --version would print srt's version.

Fix. sandbox_command now returns srt --settings <file> -- <argv…>.

  • The commander parser bundled with srt drops the -- and keeps every later argument as an operand (lib/command.js, arg === '--').
  • The settings file, allowWrite, denyWrite and denyRead are unchanged. No grant was added.
  • Regression test: test_both_sandbox_wrappers_disable_general_network_and_protect_lock now pins the exact Claude argv. It fails on the old joined form.

Campaign run 5 (python3 -m unittest tests.native_dependency_campaign, final code): exit 0, 2 tests OK. The full record is in docs/dependency-preparation-campaign.md.

Executor Fixture HEAD Command Exit Observed
Claude 9586150219c4896f3b5dad3a720bb0200b904fc3 srt --settings … -- npm --version 0 10.9.8
Claude same srt --settings … -- npm ci --ignore-scripts --no-audit --no-fund --cache <new cache> 0 added 2 packages; status prepared
Claude same srt --settings <no domains> -- node -e "if (!require('is-number')(42)) process.exit(1)" 0 lockfile bytes and HEAD unchanged
Codex ea0c809582a8ec5ee1d0ebbfccddd87324930a13 codex sandbox --permission-profile code_cycle_prepare … -- npm --version 0 10.9.8
Codex same codex sandbox … -- npm ci … 0 added 2 packages; status prepared
Codex same codex sandbox … (no domains) -- node -e … 0 lockfile bytes and HEAD unchanged

Each fixture is a fresh npm workspace with no node_modules and a new download cache, so this is the cold case.

Not covered by the campaign:

  • pnpm and Yarn under a native sandbox; only npm ran.
  • A complete dispatched stage, end to end. Fixture tests cover the stage wiring.

Verification (agent-reported, Linux/WSL, Claude stage)

Command Exit Observed
python3 -m unittest tests.native_dependency_campaign (before the fix) 1 Codex passed; Claude failed, npm --version: command not found (exit 127)
python3 -m unittest tests.native_dependency_campaign (final code) 0 2 tests OK; Claude and Codex both prepared, lookup exit 0
python3 -m unittest tests.test_dependency_setup 0 19 tests OK
python3 -m unittest discover -s tests 0 1639 tests OK
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran; root discovery finds nothing, so this proves nothing

The boundary check ran: the native campaign drives the real srt and codex sandbox.

Environment assumptions:

  • Shared with CI: the fixtures set their own Git identity.
  • Not shared with CI: the real srt, rg, codex sandbox, and registry access. Only the native campaign uses them, and it sits outside test_*.py discovery.

Post-change review

  • Fix-delta review, inline. Delta base: aca7b76f4dce27b069f174302657ba493e454e95, the latest trusted rereview receipt. It is an ancestor of bf2d3a2. Diff: 4 files, +341/−57, including def7bdb's scratch-copy install. No findings.
  • Security triage. The default triggers apply because this round changes the sandbox wrapper argv.
    • Arguments still reach srt as fixed manager argv, each shell-quoted by srt itself.
    • No grant, network domain or host write changed. No vulnerability was found.

CI (parallel policy, read once, not waited on)

Head bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0: no check runs were registered when I read them right after the push. 0 passed, 0 failed, 0 pending.

Residual risk

  • pnpm and Yarn have not run under a native sandbox; only npm has.
  • Staging copies every tracked file under the lock root once per preparation. This is slow on very large monorepos.
  • A file: dependency outside the lock root is not staged. Its install fails visibly rather than silently.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCT-20261020-005] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:cffd87a84d7798c5414c19fff7ebb9a397c9fcea · schema:2

[CCT-20261020-006] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:def7bdb33c0c405c2689168da571f3044b2633d3 · schema:2

[CCR-20261020-006] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: REVIEW_PASSED_AWAITING_CI. I rereviewed head bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0 in full.

  • REV-001…REV-004 are still resolved.
  • REV-005 is now resolved. The PR includes the passing native campaign record that REV-005 asked for, and I checked the srt argv fix it depends on.
  • No new findings.

This is not an approval. None of this head's checks had finished when I read them, so the cycle's CI gate decides.

What changed since the previous review

The previous rereview, CCR-20261020-005, reviewed aca7b76. Three commits have landed since:

  • cffd87a: preparation created the dependency output directories on the host before granting writes. def7bdb superseded this.
  • def7bdb: the frozen install now runs in a scratch copy of the lock root's tracked files.
    • The sandbox can write only that scratch directory and the download cache. The checkout and .git are never writable.
    • After a successful install, the host moves the finished node_modules, plus untracked Yarn outputs, into the checkout.
    • It re-checks those paths for symlinks and escape just before the move.
  • bf2d3a2: the Claude wrapper is now srt --settings <file> -- <argv…>. Before, it passed one pre-joined string.

I reread the whole accumulated diff against origin/main (merge base bbd3149274f07591f30e1374d3188778e243bad6). I used the runtime-supplied file and confirmed its 1972 lines. The PR head matches bf2d3a2.

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged since the previous review.

Verified by execution on this head: tests.test_stage_dispatch and tests.test_dependency_setup pass. They include:

  • test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains
  • test_codex_publishing_dispatch_keeps_code_host_and_registry_domains
  • test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. Still resolved, and the margin is larger now. The only read rules left are the staged lockfile and manifests inside scratch.

test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument passes on this head. The Codex argv captured in my native run below lists exactly one write rule and three read rules.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. These pass on this head:

  • test_preparation_role_gating_and_evidence_reach_each_native_prompt
  • test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent
  • test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies, with the staged install and the new -- fixture parsing

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md. Unchanged and still accurate; checked by reading the diff.

[REV-005] · medium · resolved · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

scripts/dependency_setup.py, tests/test_dependency_setup.py, docs/dependency-preparation-campaign.md

CCR-20261020-005 set the closing condition: run the campaign from a host executor where the native sandboxes work, then attach the passing install and lookup evidence, exit statuses and HEAD. Each part is met on this head:

  • The record is there. docs/dependency-preparation-campaign.md now says Status: **PASSED**. Run 5 lists each command, exit code and fixture HEAD.
    • Claude (9586150…): srt … -- npm --version exit 0; npm ci exit 0, prepared; no-network node -e lookup exit 0.
    • Codex (ea0c809…): the same three steps, all exit 0.
    • For both, the lockfile and HEAD were unchanged.
  • The record matches the code. The argv in run 5 is the argv that sandbox_command builds on this head. The verification settings path matches tests/native_dependency_campaign.py.
  • I checked the fix against the installed srt. In @anthropic-ai/sandbox-runtime 0.0.81, dist/cli.js defines its own .version(...) (line 159) and an operand [command...] (line 271). It builds the command with quote(commandArgs) (line 446).
    • So a pre-joined string ran as one word, which explains the exit 127 that run 5 recorded on def7bdb.
    • A bare npm --version would have printed srt's own version.
    • -- fixes both.
  • The argv is pinned by a test. test_both_sandbox_wrappers_disable_general_network_and_protect_lock checks the exact [srt, --settings, <file>, --, npm, ci, --ignore-scripts] and passes.

I could not re-run the campaign end to end here. python3 -m unittest tests.native_dependency_campaign exited 1 in this review sandbox, failing before either package manager ran:

  • claude: srt --settings … -- npm --version exit 1, Error: listen EPERM: operation not permitted …/srt-mux-11-0.sock. This sandbox blocks the Unix socket srt needs. On aca7b76 the failure was a missing srt; this run got past that and was stopped by the reviewer's sandbox.
  • codex: codex sandbox … -- npm --version exit 1, bwrap: No permissions to creating new namespace. Nested bwrap is not possible here, as CCR-20261020-005 also saw.

So this resolution rests on three things: the host-executor record that REV-005 required, the argv fix checked against the installed srt source, and the passing regression test. It does not rest on a native install in this sandbox. The disposition stays valid.

New findings

None.

I checked the delta for these and found no defect:

  • symlinks or escape on output paths before host moves (_replace unlinks links and never follows them);
  • a failed install leaving the checkout's outputs untouched;
  • tracked Yarn releases and plugins never being overwritten;
  • _installed_digest/receipt reuse after the move;
  • placeholder-only outputs (dot-entries) not counting as an install.

Security triage

The audit ran. .code-cycle.yml has no security_review.always_when rule, so the default triggers apply: this delta changes sandbox filesystem grants, host-side writes and the sandbox wrapper argv. The cc-security-review pass ran inline in this reviewer.

No vulnerability found:

  • Sandbox writes shrank. They went from checkout outputs to scratch and the download cache only. .git and the checkout are never granted.
  • Host writes are bounded. They touch only output paths re-checked just before the move. rmtree/move do not follow links, and nothing the sandbox produced runs on the host.
  • The srt argv is safe. It passes fixed manager argv after --, and srt quotes each argument itself. No shell string is built from data.
  • Grants are unchanged. No network domain, credential or publication surface changed. HOME/TMPDIR stay in scratch, and credential variables are still dropped.

Verification (executed in this rereview's clone, Linux/WSL)

Command Exit Observed
python3 -m unittest discover -s tests 1 1639 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran: discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_stage_permissions tests.test_run_cycle tests.test_issue_review tests.test_host_permissions 0 412 tests OK
python3 -m unittest tests.native_dependency_campaign 1 2 failures, both from this sandbox (see REV-005)

The suite's non-passes are the same environmental ones the earlier reviews recorded. They are in code this PR does not change:

  • All 62 errors are in test_validate_package. copytree hits [Errno 13] Permission denied on dotfiles this sandbox masks.
  • The 1 failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout. The message is "no temporary directory outside the dispatch checkout": this sandbox has no writable /tmp or /var/tmp.

Unverified

  • A native install inside this review sandbox, for the reasons above. The PR's run 5 record is the evidence.
  • The SHA-256 of the supplied diff file: there is no hashing command in this stage's table. The head SHA and line count match.

CI (parallel policy, read once, not waited on)

Head bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0:

Check State
Skills, manifests, and Bash installer pending (in progress)
Windows test shard (windows-1) pending (in progress)
Windows test shard (windows-2) pending (in progress)
Windows test shard (windows-3) pending (in progress)
Windows test shard (windows-4) pending (in progress)
PowerShell installer not registered on this head when read (it ran on aca7b76)

0 passed, 0 failed, 5 pending. The cycle's CI gate waits for them and decides.

Residual risk

  • Yarn 2+ and pnpm are unproven under native sandboxes; only npm ran. One possible issue I could not verify here (Context7 was denied in this stage), so it is not a finding:
    • Yarn 2+ installs run with HOME set to scratch. If Yarn's global cache is in use, .pnp.cjs may point at a cache under the deleted scratch HOME.
    • Its relative paths are also computed from the scratch tree, not the checkout.
    • A native Yarn 2+ run would settle this.
  • Files tracked under node_modules would be dropped, as npm ci would also do.
  • Staging copies every tracked file under the lock root once per preparation, which is slow on large monorepos.
  • A file: dependency outside the lock root is not staged. Its install fails visibly.
  • Codex issue_review has no code-host route. It relies on host-supplied context.
  • Claude's registry sandbox also allows the code hosts. "Default code-host domains only for publishing stages" holds for Codex only.
  • The PR is still a draft.

Verdict: REVIEW_PASSED_AWAITING_CI. No blocking findings.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCT-20261020-005] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:cffd87a84d7798c5414c19fff7ebb9a397c9fcea · schema:2

[CCT-20261020-006] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:def7bdb33c0c405c2689168da571f3044b2633d3 · schema:2

[CCR-20261020-006] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-007] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0 · schema:2

Status: RESOLVED. This round fixes the one failed required check of the reviewed head bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0. The fix is in commit 82bd51b15bce7812f487c0ba7fef9c0b45fe7277.

The review findings are unchanged. All five stay resolved, as CCR-20261020-006 judged. The CI failure was not a finding and is not published as one.

Failed check of the reviewed head

The failure was Windows test shard (windows-2). PowerShell installer also failed, but it is only the aggregating gate ("Require all Windows test shards to pass"). It ran exit 1 because windows-2 failed.

  • Failing test: test_dependency_setup.SetupTests.test_install_runs_in_a_scratch_copy_and_replaces_checkout_outputs.
  • Cause, within this change: the test was added in def7bdb. It built the scratch-copy listing with str(path.relative_to(cwd)), which gives apps\web on Windows, then compared that listing with the POSIX literals apps/web and apps/web/package.json.
  • Not a product defect: preparation itself returned prepared on Windows. Only the test's way of writing paths depended on the OS.
  • Fix: the test now uses path.relative_to(cwd).as_posix(). Sorting is the same on both OSes for this fixture.
  • Other sites checked: two other str(path.relative_to(...)) sites in scripts/dependency_setup.py stay unchanged. One is a cache digest computed and compared on the same host. The other is a needs_build report string. Neither is compared across OSes, and neither failed.

Findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged in this round.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. Unchanged in this round.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. Unchanged in this round. The single-line test edit does not touch the wiring tests.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

Unchanged in this round.

[REV-005] · medium · resolved · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

docs/dependency-preparation-campaign.md. Unchanged in this round.

Verification (agent-reported)

Level Command Exit Result
test python3 -m unittest discover -s tests 0 1639 tests, OK
static python3 scripts/validate-package.py 0 VALID: 16 skills, shared sections in sync, manifests aligned

These ran on Linux (WSL2), not Windows, so they do not reproduce the Windows separator directly. The fix removes the dependence on the OS separator, so Windows CI on the new head is the boundary check.

The local run shares this with CI: no dependence on the global Git identity or credentials. It does not share the Windows filesystem.

Post-change review

  • Delta base: bf2d3a2, the head of the latest trusted rereview receipt. It is an ancestor of 82bd51b, confirmed with git merge-base --is-ancestor.
  • Delta: tests/test_dependency_setup.py, 1 line. I reviewed it inline and found nothing.
  • Security triage: test-only change, so no security audit is triggered.

Checks of the pushed head

Head 82bd51b15bce7812f487c0ba7fef9c0b45fe7277, read once right after the push under the parallel CI policy. No check runs were registered yet (statusCheckRollup: []), so all six expected checks are pending:

  • Skills, manifests, and Bash installer
  • PowerShell installer
  • Windows test shard (windows-1), (windows-2), (windows-3) and (windows-4)

None of them has passed yet. The cycle's CI gate decides. This is not an approval.

@datacas

datacas commented Oct 20, 2026

Copy link
Copy Markdown
Owner Author

Rereview — PR #287 (work item #279)

[CCR-20261020-001] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-001] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:4f1532a34b74984452a3b3e1d902cc61c2d4b0e8 · schema:2

[CCR-20261020-002] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-002] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:8bfbba9bae3ad3084e39ab81d6f18e3691ec39c4 · schema:2

[CCR-20261020-003] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-003] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCR-20261020-004] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCR-20261020-005] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-004] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:aca7b76f4dce27b069f174302657ba493e454e95 · schema:2

[CCT-20261020-005] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:cffd87a84d7798c5414c19fff7ebb9a397c9fcea · schema:2

[CCT-20261020-006] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:def7bdb33c0c405c2689168da571f3044b2633d3 · schema:2

[CCR-20261020-006] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

[CCT-20261020-007] · deep_coder · anthropic/claude-opus-5-5→? · high · triaged:bf2d3a2e57b25d604e0ed2fb7916b57b3c4491b0 · schema:2

[CCR-20261020-007] · senior_reviewer · anthropic/claude-opus-5-5→? · high · schema:2

Verdict: APPROVED. I rereviewed head 82bd51b15bce7812f487c0ba7fef9c0b45fe7277 in full.

  • REV-001…REV-005 stay resolved.
  • No new findings.
  • Every check of this head has passed, including both required checks.

The PR is still a draft. Merging remains a human decision.

No earlier comment carries the receipt of attempt-2e571c6247e4457087d267ea11755381, so this is a new comment rather than an update.

What changed since the previous review

CCR-20261020-006 reviewed bf2d3a2. One commit has landed since, 82bd51b. It changes one line in tests/test_dependency_setup.py:

  • test_install_runs_in_a_scratch_copy_and_replaces_checkout_outputs now builds its scratch-copy listing with path.relative_to(cwd).as_posix() instead of str(...).
  • Before, Windows produced apps\web, which never matched the POSIX literals the test compares against. That broke Windows shard 2 on bf2d3a2.
  • Product code is unchanged. Sorting the six fixture entries gives the same order on both OSes.

I reread the whole accumulated diff against origin/main (merge base bbd3149274f07591f30e1374d3188778e243bad6). I used the runtime-supplied file and confirmed its 1972 lines (21 files, +1484/−39). The PR head matches 82bd51b.

Previous findings

[REV-001] · high · resolved · valid · blocks:yes — Every Codex stage with a command policy now gets code-host network, including stages that must not publish

scripts/executors.py. Unchanged since the previous review. Verified by execution on this head: tests.test_stage_dispatch passes, including test_codex_nonpublishing_dispatches_do_not_get_default_code_host_domains and test_codex_publishing_dispatch_keeps_code_host_and_registry_domains. tests.test_dependency_setup passes, including test_nonpublishing_codex_registry_choice_does_not_grant_code_host_route.

[REV-002] · medium · resolved · valid · blocks:yes — Codex preparation puts every tracked file in one -c argument, which exceeds the kernel's per-argument limit on medium repos

scripts/dependency_setup.py. Unchanged. test_large_tracked_source_tree_does_not_inflate_codex_filesystem_argument passes on this head.

[REV-003] · medium · resolved · valid · blocks:yes — No test exercises the dispatch-time preparation wiring; the review/rereview "clean clone" test calls prepare itself

tests/test_stage_dispatch.py, tests/test_dependency_setup.py. These pass on this head:

  • test_preparation_role_gating_and_evidence_reach_each_native_prompt
  • test_preparation_exception_reaches_prompt_and_artifacts_without_skipping_agent
  • test_fresh_review_and_rereview_cross_process_boundary_without_source_dependencies

The one-line delta does not touch them.

[REV-004] · low · resolved · valid · blocks:no — The docs promise that choices never grant force-push or merge, but a selected interpreter or wrapper bypasses the guard

docs/dependency-preparation.md, docs/host-permissions.md, docs/routing.md. Unchanged and still accurate. I checked this by rereading the diff.

[REV-005] · medium · resolved · valid · blocks:yes — The native Claude/Codex validation campaign, which #279's acceptance criteria require, has not passed

docs/dependency-preparation-campaign.md, scripts/dependency_setup.py. Unchanged since CCR-20261020-006 accepted it. Run 5 is still the record, and its srt … -- <argv> form still matches what sandbox_command builds. test_both_sandbox_wrappers_disable_general_network_and_protect_lock pins that argv and passes on this head.

I did not re-run the native campaign here. The reason is in Unverified.

New findings

None. I checked the delta for:

  • other OS-dependent path comparisons in the new tests;
  • the two remaining str(path.relative_to(...)) sites in scripts/dependency_setup.py.

Neither site is compared across hosts: one is a same-host cache digest and the other a report string. Windows CI passes on all four shards.

Security triage

Not a sensitive change: the security audit was skipped after triage. The delta since the last audited head (bf2d3a2, audited in CCR-20261020-006) is one line of test code. It changes no sandbox grant, network domain, credential handling, host write or publication path. The accumulated diff's security-relevant surface is unchanged since that audit.

Verification (executed in this rereview's clone, Linux/WSL)

Command Exit Observed
python3 -m unittest discover -s tests 1 1639 tests; 62 errors + 1 failure, all environmental (below)
python3 scripts/validate-package.py 0 VALID: 16 skills (7 cycle, 9 supporting), shared sections in sync, cross-agent manifests aligned
python3 -m unittest 0 0 tests ran. Discovery from the root finds nothing, so this configured command proves nothing
python3 -m unittest tests.test_dependency_setup tests.test_stage_dispatch tests.test_stage_permissions tests.test_run_cycle tests.test_issue_review tests.test_host_permissions 0 412 tests OK, including the edited test

The suite's non-passes are the same environmental ones CCR-20261020-005 and CCR-20261020-006 recorded, in code this PR does not change:

  • All 62 errors are in test_validate_package. Each is [Errno 13] Permission denied from copytree, on dotfiles this sandbox masks (62 of 62 counted).
  • The 1 failure is test_executors.ReadOnlyVerificationTests.test_scratch_never_uses_a_temp_parent_inside_the_checkout, with "no temporary directory outside the dispatch checkout". This sandbox has no writable /tmp or /var/tmp.

On Linux, test_install_runs_in_a_scratch_copy_and_replaces_checkout_outputs also passed when run alone (exit 0). On Windows, CI's shards cover it.

Unverified

  • The Windows path behaviour of the edited test. This clone runs on Linux. CI's Windows shard 2 passed it on this head, which is the boundary evidence.
  • A native install in this review sandbox. I did not re-run the native campaign. Earlier reviews showed this sandbox blocks both nested wrappers, and the delta does not touch preparation. The PR's run 5 record remains the evidence.
  • The SHA-256 of the supplied diff file. This stage's command table has no hashing command. The head SHA and line count match.

CI (parallel policy, read once, not waited on)

Head 82bd51b15bce7812f487c0ba7fef9c0b45fe7277:

Check Required State
Skills, manifests, and Bash installer yes passed
PowerShell installer yes passed
Windows test shard (windows-1) no passed
Windows test shard (windows-2) no passed
Windows test shard (windows-3) no passed
Windows test shard (windows-4) no passed

6 passed, 0 failed, 0 pending. Both required checks passed.

Residual risk

These carry over from CCR-20261020-006. None is a finding:

  • Yarn 2+ and pnpm are unproven under native sandboxes. Only npm ran. Yarn 2+'s .pnp.cjs might point at a cache under the deleted scratch HOME.
  • Files tracked under node_modules would be dropped, as npm ci would also do.
  • Staging copies every tracked file under the lock root on each preparation.
  • A file: dependency outside the lock root is not staged. Its install fails visibly.
  • Codex issue_review has no code-host route. It relies on host-supplied context.
  • Claude's registry sandbox also allows the code hosts. "Default code-host domains only for publishing stages" holds for Codex only.
  • The PR is still a draft.

Verdict: APPROVED. No blocking findings. All checks of the reviewed head passed.

@datacas
datacas marked this pull request as ready for review October 20, 2026 13:08
@datacas
datacas merged commit 310d706 into main Oct 20, 2026
6 checks passed
@datacas
datacas deleted the issue-279-sandbox-dependency-setup branch October 20, 2026 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep development moving through routine sandbox and dependency setup

1 participant