Skip to content

fix(cli): resolve config from main worktree - #258

Merged
datacas merged 4 commits into
mainfrom
issue-249-shared-config-resolver
Oct 17, 2026
Merged

datacas merged 4 commits into
mainfrom
issue-249-shared-config-resolver

Conversation

@datacas

@datacas datacas commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner

Resolves the linked-worktree configuration gap in cc-profile-config and cc-stats for #249.

Diagnosis

From a linked worktree without its own .code-cycle.yml, cc-profile-config show silently selected built-in defaults and cc-stats failed to find the repository selector, even when the main worktree had the configuration. In a disposable linked-worktree reproduction, profile-config exited 0 with the default cheap_coder target; stats exited 2 with no repository identity. The issue's hypothesis was confirmed: both readers looked only at <cwd>/.code-cycle.yml.

The invariant is that all toolkit readers use the same configuration precedence: explicit path when supported, current worktree file, main worktree root file, then defaults where allowed. This change shares the resolver in run_cycle.py, reports the selected absolute path on stderr, and keeps stdout unchanged. Profile writes from a linked worktree target the main worktree file when no local file exists; the target is shown before confirmation and checked against the repository's main worktree before the atomic write.

Related work searched: #244 / merged PR #248 introduced the runtime resolver; #234 is a broader closed tracker; open #186 concerns a future stats.py refactor and does not share this defect. No other open item is addressed.

Work units

Unit Behaviour Files Tests Verification Rollback
WU-1 Resolve and report configuration consistently from both CLI tools; constrain linked-worktree writes to the repository config scripts/run_cycle.py, scripts/profile_config.py, scripts/stats.py, both CLI skill docs tests/test_profile_config.py, tests/test_stats.py Focused suites, full unittest suite, static checks, and disposable linked-worktree CLI boundary independent

Verification

Agent-reported local results:

  • rtk python3 -m unittest discover -s tests -p test_profile_config.py -q — passed, 29 tests.
  • rtk python3 -m unittest discover -s tests -p test_stats.py -q — passed, 42 tests.
  • rtk python3 -m unittest discover -s tests -q — passed, 1,470 tests.
  • rtk git diff --check — passed.
  • rtk python3 -m compileall -q scripts/profile_config.py scripts/stats.py scripts/run_cycle.py — passed.
  • rtk python3 /tmp/cc249_boundary.py — passed: both read CLIs used the main worktree config and kept JSON on stdout; confirmed write changed only the main config; foreign target was rejected.

The local checks use Python 3 and Git with disposable temporary repositories; the fixture sets its own Git author. No shared service, credentials, or user-global Git identity is required.

Closes #249

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

Implementation summary: issue #249 is implemented in this change request. Both CLI tools now use the shared worktree → main worktree configuration resolver and report the selected source on stderr. Confirmed profile writes target the main config when appropriate, and foreign targets are rejected. Local focused and full-suite verification passed; the checks for this pushed head are being recorded once under the parallel CI policy.

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCR-20260916-258] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Initial review — PR #258 (work item #249)

Status: CHANGES_REQUESTED — reviewed head fdaad2b211149c048017a2324ebabda61156856d against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1 (380-line accumulated diff, SHA-256 confirmed).

Summary

The shared resolver (resolve_config_path / config_search_paths in run_cycle.py) correctly fixes the linked-worktree gap for cc-stats and cc-profile-config show. The linked-worktree write guard works. One regression: profile_config --config <path> now fails for a file that does not exist yet.

Findings

[REV-001] · medium · open · - · blocks:yes — --config <new path> no longer creates a configuration file

Path: scripts/profile_config.py:609-620 (_load) via scripts/run_cycle.py resolve_config_path.
Before, _load returned (Path(config), {}) for a nonexistent explicit path, so write --config new.yml --confirmed created it and show --config missing.yml fell back to defaults. Now resolve_config_path raises no configuration at <path>.
Observed on head in an empty repo: profile_config.py write --cwd R --config R/new.yml --preset single-anthropic --no-probe --confirmed → profile_config: no configuration at …/new.yml, exit 1, no file written. The same command on cad0b88 wrote the file. No test or documentation covers the change (--config is documented only as "path to .code-cycle.yml"). Without --config, a missing file still works and creates <cwd>/.code-cycle.yml.
Fix: in _load, keep an explicit --config path that does not exist as (path, {}) (read-only commands may keep the new error if that is intended, but then document it), and add a regression test for write --config <new>.

[REV-002] · low · open · - · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

Path: docs/configuration.md:19, :273.
The fallback to the main worktree root and the stderr configuration: line now apply to profile_config.py and stats.py, but only the two SKILL.md files were updated.

[REV-003] · low · open · - · blocks:no — Linked-worktree write guard rejects a symlinked main config

Path: scripts/profile_config.py:27-38 (_validate_write_target).
target.is_symlink() rejects any symlinked target, so a dotfile-managed .code-cycle.yml in the main worktree can be written from the main worktree but not from a linked one, with an error that only names the expected path. Consider resolving the symlink and comparing the resolved parent, or say so in the error message.

Security triage

No security_review.always_when rule is declared in .code-cycle.yml, so the defaults applied: no auth, session, secrets, dependency, CI workflow or deployment path is touched, and the rule did not fire. My own reading flagged the new write-target check (filesystem write boundary) and I examined it inline: it constrains linked-worktree writes to the resolved repository file, and a foreign --config target is rejected (tested). No confirmed vulnerability. A full cc-security-review pass was not run.

Validation executed

  • python3 -m unittest discover -s tests -q: 1470 tests, OK (exit 0), PyYAML 5.4.1 present, so the YAML-dependent tests ran.
  • Manual repro of REV-001 on cad0b88 (works) vs. fdaad2b (fails), as above.
  • Not run: Windows suite (CI only). cc-verify as a separate pass was not run; verification above was done directly.
  • Observation: the new stderr line configuration: … shows up as noise in the unittest output.

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

At review time, all five checks on this head were pending: Skills, manifests, and Bash installer, Windows test shard (windows-1), (windows-2), (windows-3), (windows-4). No check failed. The gate decides on these, not this review.

Residual risks

Windows path handling in _validate_write_target (absolute() comparison, case-insensitive paths) was not exercised locally. Each call to resolve_config now runs git rev-parse twice (minor).

Verdict

CHANGES_REQUESTED — blocking: REV-001.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-initial-review","status":"CHANGES_REQUESTED","issue_provider":"github","issue_id":"249","code_host":"github","change_request_id":"258","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/258","pr_number":258,"issue_number":249,"head_sha":"fdaad2b211149c048017a2324ebabda61156856d","reviewed_head_sha":"fdaad2b211149c048017a2324ebabda61156856d","review_run_id":"CCR-20260916-258","reviewer":{"profile":"reviewer","provider":"anthropic","model_requested":"claude-sonnet-5-5","model_resolved":null,"effort":"high"},"findings":[{"id":"REV-001","severity":"medium","status":"open","disposition":"-","blocks_approval":true,"category":"correctness","path":"scripts/profile_config.py","line":609},{"id":"REV-002","severity":"low","status":"open","disposition":"-","blocks_approval":false,"category":"documentation","path":"docs/configuration.md","line":19},{"id":"REV-003","severity":"low","status":"open","disposition":"-","blocks_approval":false,"category":"correctness","path":"scripts/profile_config.py","line":27}],"blocking_findings":["REV-001"],"checks":{"head_sha":"fdaad2b211149c048017a2324ebabda61156856d","passed":0,"failed":0,"pending":5},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCR-20260916-259] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Initial review — PR #258 (work item #249), verification of recovered attempt

Status: CHANGES_REQUESTED — reviewed head fdaad2b211149c048017a2324ebabda61156856d (unchanged, equals the PR's current head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 380-line accumulated diff was read in full (SHA-256 4c4c2e92…067ecf6 confirmed). Convention applied: no CLAUDE.md/CONTRIBUTING.md; AGENTS.md contains only tool routing.

Recovered attempt attempt-99e90e7b63ef43098db268d80157fe81 (trusted author datacas) claimed no resolutions, so no claimed IDs needed verification. I re-verified its three findings independently on this head. All remain open; none is new, none is obsolete.

Findings

[REV-001] · medium · open · - · blocks:yes — --config <new path> no longer creates a configuration file

Path: scripts/profile_config.py:609-620 (_load) via scripts/run_cycle.py resolve_config_path.
Reproduced at runtime on an empty Git repo:

  • head: profile_config.py write --config R/new.yml --preset single-anthropic --no-probe --confirmed → no configuration at R/new.yml, exit 1, no file.
  • head: show --config R/missing.yml → same error, exit 1.
  • base cad0b88: the write created new.yml; the show exited 0 with defaults.
    No test or documentation covers the change. Fix: keep a nonexistent explicit --config as (path, {}) in _load (or document the new strictness for read-only commands) and add a regression test for write --config <new>.

[REV-002] · low · open · - · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

Path: docs/configuration.md:19. The main-worktree fallback and stderr configuration: line now also apply to profile_config.py and stats.py; only the two SKILL.md files were updated.

[REV-003] · low · open · - · blocks:no — Linked-worktree write guard rejects a symlinked main config

Path: scripts/profile_config.py:27-38 (_validate_write_target).
Reproduced: main config is a symlink; write --cwd <main> → exit 0, write --cwd <linked> → exit 1 configuration write target must be …/.code-cycle.yml for this repository, which names the very path being refused. Resolve the symlink before comparing, or explain it in the message.

Verified findings

ID Outcome
REV-001 still_open
REV-002 still_open
REV-003 still_open

Security triage

.code-cycle.yml declares no security_review.always_when, so the defaults applied and the rule did not fire (no auth, session, secrets, dependency, workflow or deployment path changed). My own reading flagged the new write-target check (filesystem write boundary); I inspected it inline: a foreign --config target is rejected from a linked worktree (covered by test_linked_worktree_write_rejects_a_foreign_config_target). No confirmed vulnerability. A separate cc-security-review pass was not run.

Validation executed

  • REV-001 and REV-003 reproduced against head and (for REV-001) base cad0b88, as above; REV-002 confirmed by reading docs/configuration.md:19.
  • Not re-run: the full unittest suite (the recovered review recorded 1470 tests OK on this head). Separate cc-verify pass not run.
  • Windows behaviour of _validate_write_target (absolute() comparison, case-insensitive paths) was not exercised locally; CI log text for the failing shards was not retrievable while the run was in progress.

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

Skills, manifests, and Bash installer: pass · Windows test shard (windows-1): pass · Windows test shard (windows-2): pending · Windows test shard (windows-3): fail · Windows test shard (windows-4): fail. Reported as state only, not as findings; the CI gate decides.

Residual risks

Windows path handling in the write guard (see above), plus the failing windows-3/windows-4 shards whose cause is not established by this review. resolve_config now runs git rev-parse twice per call (minor).

Verdict

CHANGES_REQUESTED — blocking: REV-001.

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCR-20260916-258] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20260916-259] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCT-20261016-001] · cheap_coder · openai/gpt-6-luna→? · high · triaged:fdaad2b211149c048017a2324ebabda61156856d · schema:2

Resolution — PR #258 (work item #249)

All findings were classified as valid against triage head fdaad2b211149c048017a2324ebabda61156856d, before changes. The trusted review base is an ancestor of the pushed head.

Applied fixes

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> creates a configuration file

Path: scripts/profile_config.py, tests/test_profile_config.py.
Restored the empty-config behavior for a nonexistent explicit path. A confirmed write creates it; read-only commands can continue using built-in defaults. Added regression coverage.

[REV-002] · low · resolved · valid · blocks:no — Document config fallback for profile-config and stats

Path: docs/configuration.md.
Documented the main-worktree fallback, stderr/stdout behavior, explicit new config paths, and symlink write behavior.

[REV-003] · low · resolved · valid · blocks:no — Follow symlinked config targets from linked worktrees

Path: scripts/profile_config.py, tests/test_profile_config.py.
Writes validate resolved paths and write through symlinks so atomic replacement preserves the link in main and linked worktrees. Symlink loops produce a handled CLI error; an unrelated default-config loop does not block a valid explicit --config write.

Verification

  • python3 -m unittest discover -s tests -p test_profile_config.py -q — passed, 34 tests.
  • python3 -m unittest discover -s tests -p test_stats.py -q — passed, 42 tests.
  • python3 -m unittest discover -s tests -q — passed, 1,475 tests.
  • python3 scripts/validate-package.py — passed.
  • python3 -m compileall -q scripts/profile_config.py scripts/run_cycle.py scripts/stats.py tests/test_profile_config.py tests/test_stats.py — passed.
  • Real CLI boundary checks passed for explicit file creation, linked-worktree symlink writes, explicit config with an unrelated symlink loop, and clean error handling for a loop.
  • git diff --check passed. The 175-line fix delta from fdaad2b211149c048017a2324ebabda61156856d (SHA-256 5109bf608b47be7e6bc77bc9163ab16adda7201cf6d10b0c8cacd0d51b1ba905) received a post-fix code review with no confirmed findings.

Checks of pushed head

Head: 75e17b4cc1c9a51e03782bae8878edc5a62c954f. The single post-push GitHub read returned an empty statusCheckRollup. The five expected gates were absent from that snapshot (recorded as missing, not as observed failures): Skills, manifests, and Bash installer; Windows test shard (windows-1); Windows test shard (windows-2); Windows test shard (windows-3); Windows test shard (windows-4). Counts: 0 passed, 5 missing/failed-count, 0 pending. No remote wait or in-stage CI fix round was run; the parallel CI gate handles check failures separately.

@datacas

datacas commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner Author

[CCR-20261016-260] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-262] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Rereview — PR #258 (work item #249), current head after fixes

Status: REVIEW_PASSED_AWAITING_CI — reviewed head 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 501-line accumulated diff was read (SHA-256 c944b664…ca25a confirmed). Previous reviewed head: 75e17b4cc1c9a51e03782bae8878edc5a62c954f. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md.

This comment already carried the receipt of earlier attempt attempt-d1bbd89d056c454bb17919b5cb58768d (its review of 75e17b4 is kept below, unchanged). This attempt adds its own receipt here rather than posting a second comment. It is a completed review of this head, not an approval; the CI gate waits for the checks.

What changed since the previous review

75e17b4..7cd4ade touches only tests/test_profile_config.py and tests/test_stats.py: path assertions now compare .resolve() forms, to avoid the Windows RUNNER~1 / runneradmin mismatch. No product code changed. The stats test for a missing identity no longer asserts that local paths are absent from the error; the error now names the searched paths on purpose (documented in skills/cc-stats/SKILL.md).

Previous findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

Re-verified on this head in an empty repo: write --config R/new.yml --preset single-anthropic --no-probe --confirmed → exit 0, file created; show --config R/missing.yml → exit 0 with built-in defaults. Covered by test_explicit_new_config_path_can_be_created.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

docs/configuration.md:19 and :273 describe the main-worktree fallback, stderr reporting, explicit new paths and symlink handling for profile_config.py and stats.py.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

Re-verified: main .code-cycle.yml symlinked to a file outside the repo; write --cwd <linked> → exit 0, the real file gained profiles, the symlink is intact, nothing created in the linked worktree. A foreign --config from the linked worktree → exit 1 naming the expected path, file untouched. stats.py --cwd <linked> → exit 0, configuration: line on stderr.

New findings

None.

Security triage

.code-cycle.yml declares no security_review.always_when rule; defaults applied: no auth, session, secrets, dependency, workflow or deployment path changed (the fix delta is tests only). Not a sensitive change: the security audit was skipped after triage. My own reading of the filesystem write boundary in _validate_write_target found no confirmed vulnerability.

Validation executed

  • python3 -m unittest discover -s tests -q: 1475 tests, OK (exit 0); working tree unchanged afterwards.
  • test_profile_config.py 34 tests OK; test_stats.py 42 tests OK.
  • Runtime repros above (REV-001, REV-003, foreign target, stats from a linked worktree).
  • Not run: Windows locally. A separate cc-verify pass was not run; checks were executed directly.

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

gh pr checks 258 on 7cd4ade: Skills, manifests, and Bash installer pass · Windows test shard (windows-1) pass · (windows-2) pass · (windows-3) pass · (windows-4) fail · PowerShell installer fail. 4 passed, 2 failed, 0 pending. State only, not a finding; the CI gate decides. For the gate: the windows-4 log shows test_write_reports_a_symlink_loop_without_a_traceback failing with AssertionError: 1 != 0 (exit code 0 where 1 was expected) on Windows. The PowerShell installer cause was not examined.

Residual risks

Windows symlink/loop behaviour of _validate_write_target and its test is only exercised by the CI shards. resolve_config still runs git rev-parse twice per call (minor).

Verdict

REVIEW_PASSED_AWAITING_CI — no open finding blocks approval; required checks have not all passed.


Earlier record — attempt attempt-d1bbd89d056c454bb17919b5cb58768d (head 75e17b4), preserved

Rereview — PR #258 (work item #249)

Status: REVIEW_PASSED_AWAITING_CI — reviewed head 75e17b4cc1c9a51e03782bae8878edc5a62c954f (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 501-line accumulated diff was read (SHA-256 4a68106a…ea53 confirmed), plus the fix delta fdaad2b..75e17b4 (docs, profile_config.py, tests). Previous reviewed head: fdaad2b211149c048017a2324ebabda61156856d. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md.

This is a completed review of this head, not an approval. The CI gate waits for the checks.

What changed since the previous review

_load keeps a nonexistent explicit --config as (path, {}); _validate_write_target now resolves symlinks and returns the path to write; docs/configuration.md documents the fallback, the explicit-new-path behaviour and symlink handling; five new tests.

Previous findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> creates a configuration file

Reproduced on this head in an empty Git repo: write --config R/new.yml --preset single-anthropic --no-probe --confirmed → exit 0, file created; show --config R/missing.yml → exit 0 with defaults. Regression test added in tests/test_profile_config.py.

[REV-002] · low · resolved · valid · blocks:no — Document config fallback for profile-config and stats

docs/configuration.md:19 and the profile_config.py entry now describe the main-worktree fallback, stderr reporting, new explicit paths and symlink behaviour.

[REV-003] · low · resolved · valid · blocks:no — Follow symlinked config targets from linked worktrees

Reproduced: main .code-cycle.yml is a symlink to a file elsewhere; write --cwd <linked> → exit 0, the real file was updated and the symlink in the main worktree is intact. A foreign --config from the linked worktree → exit 1 with the expected-path error and no file written. A symlink loop → handled profile_config: cannot resolve configuration write target … error, no traceback.

New findings

None.

Security triage

.code-cycle.yml declares no security_review.always_when rule, so the defaults applied: no auth, session, secrets, dependency, workflow or deployment path changed. My own reading flagged the filesystem write boundary in _validate_write_target; I inspected it inline and exercised it (foreign target rejected from a linked worktree, symlink followed to the repository's config only, loop handled). No confirmed vulnerability. A separate cc-security-review pass was not run.

Validation executed

  • python3 -m unittest discover -s tests -q: 1475 tests, OK (exit 0).
  • Runtime repros for REV-001 and REV-003 on the head, as above.
  • Not verified: Windows behaviour of the resolved-path comparison (CI only). Separate cc-verify pass not run; checks were run directly.

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

gh pr checks 258 at review time: Skills, manifests, and Bash installer pending · Windows test shard (windows-1) pending · (windows-2) pending · (windows-3) pending · (windows-4) pending. 0 passed, 0 failed, 5 pending. State only; the CI gate decides.

Residual risks

Windows path comparison in the write guard (resolve() on case-insensitive paths) is exercised only by the pending shards. resolve_config still runs git rev-parse twice per call (minor).

Verdict

REVIEW_PASSED_AWAITING_CI — no open finding blocks approval; required checks have not all passed.

ORCHESTRATION_RESULT (JSON)

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

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCR-20261016-260] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-261] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Rereview — PR #258 (work item #249), verification of recovered attempt

Status: REVIEW_PASSED_AWAITING_CI — reviewed head 75e17b4cc1c9a51e03782bae8878edc5a62c954f (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 501-line accumulated diff was read in full (SHA-256 4a68106a…ea53 confirmed). Previous reviewed head: fdaad2b211149c048017a2324ebabda61156856d. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md.

This is a completed review of this head, not an approval. The CI gate waits for the checks.

Recovered attempt attempt-d1bbd89d056c454bb17919b5cb58768d claimed REV-001, REV-002 and REV-003 resolved. I did not reuse its conclusions: each claim was verified independently by execution on this head.

Previous findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> creates a configuration file

Verified on head in an empty Git repo: write --config R/new.yml --preset single-anthropic --no-probe --confirmed → exit 0, file created; show --config R/missing.yml → exit 0 with built-in defaults. Regression test test_explicit_new_config_path_can_be_created.

[REV-002] · low · resolved · valid · blocks:no — Document config fallback for profile-config and stats

docs/configuration.md:19 and the profile_config.py entry describe the main-worktree fallback, stderr reporting, new explicit paths and symlink handling.

[REV-003] · low · resolved · valid · blocks:no — Follow symlinked config targets from linked worktrees

Verified: main .code-cycle.yml is a symlink to a file elsewhere; write --cwd <linked> → exit 0, the real file was updated, the symlink is intact. A foreign --config from the linked worktree → exit 1 with the expected-path error, file untouched. A symlink loop → handled cannot resolve configuration write target error, exit 1, no traceback.

New findings

None.

Security triage

.code-cycle.yml declares no security_review.always_when rule, so the defaults applied: no auth, session, secrets, dependency, workflow or deployment path changed. My own reading flagged the filesystem write boundary in _validate_write_target; I inspected and exercised it (foreign target rejected, symlink followed to the repository's config only, loop handled). No confirmed vulnerability. A separate cc-security-review pass was not run.

Validation executed

  • python3 -m unittest discover -s tests -q: 1475 tests, OK (exit 0), working tree unchanged afterwards.
  • Runtime repros for REV-001 and REV-003 on the head, as above; REV-002 by reading the doc.
  • Separate cc-verify pass not run; checks were run directly.

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

gh pr checks 258 at review time: Skills, manifests, and Bash installer pass · Windows test shard (windows-1) pass · Windows test shard (windows-2) pass · Windows test shard (windows-3) fail · Windows test shard (windows-4) fail · PowerShell installer fail. 3 passed, 3 failed, 0 pending. State only, not a finding; the CI gate decides. For the gate's information, the windows-4 log shows LinkedWorktreeConfigTests assertions failing on a path-form mismatch (C:\Users\RUNNER~1\… short form vs C:\Users\runneradmin\… resolved form); windows-3 and PowerShell installer causes were not examined.

Residual risks

The Windows path comparison in the write guard and the new tests is exercised only by the CI shards above. resolve_config still runs git rev-parse twice per call (minor).

Verdict

REVIEW_PASSED_AWAITING_CI — no open finding blocks approval; required checks have not all passed.

@datacas

datacas commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner Author

[CCT-20261016-001] · cheap_coder · openai/gpt-6-luna→? · high · triaged:75e17b4cc1c9a51e03782bae8878edc5a62c954f · schema:2

[CCR-20260916-258] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Resolve summary — PR #258 (work item #249)

Status: RESOLVED — the reviewed head was 75e17b4cc1c9a51e03782bae8878edc5a62c954f. The trusted review delta base was an ancestor of the published head 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c.

Review findings

Triage was against 75e17b4cc1c9a51e03782bae8878edc5a62c954f. All three findings were valid. Their fixes were already present at that triage head and were verified in this attempt:

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

The explicit missing-path handling in scripts/profile_config.py preserves the empty-config behavior, and test_explicit_new_config_path_can_be_created verifies a confirmed write creates the file.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

docs/configuration.md now documents the main-worktree fallback and stderr reporting for profile_config.py and stats.py.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

_validate_write_target resolves and follows a symlinked config target; test_linked_worktree_write_follows_a_symlinked_main_config verifies linked-worktree writes preserve the symlink and update its target.

Failed check on the reviewed head (separate from findings)

The required PowerShell installer check failed because Windows shards 3 and 4 failed path assertions. The assertions expected Windows' short RUNNER~1 spelling while the same path was reported as runneradmin; the target files and configuration behavior were correct. The tests now compare resolved paths. Fix commit: 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c.

Verification

Agent-reported local results:

  • python3 -m unittest discover -s tests -p test_profile_config.py -q — passed, 34 tests.
  • python3 -m unittest discover -s tests -p test_stats.py -q — passed, 42 tests.
  • python3 scripts/validate-package.py — passed.
  • python3 -m unittest discover -s tests -q — passed, 1,475 tests.
  • git diff --check — passed.
  • The delegated cc-code-review fix-delta pass found no findings.

The local test runs used Linux; the updated Windows assertions are awaiting the pushed head's Windows checks.

Checks of pushed head

Head 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c: 0 passed, 0 failed, 5 pending — Skills, manifests, and Bash installer, Windows test shard (windows-1), Windows test shard (windows-2), Windows test shard (windows-3), and Windows test shard (windows-4). Checks were read once under the parallel CI policy; no remote wait or fix round was run.

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCT-20261016-002] · cheap_coder · openai/gpt-6-luna→? · high · triaged:75e17b4cc1c9a51e03782bae8878edc5a62c954f · schema:2

[CCT-20261016-001] · cheap_coder · openai/gpt-6-luna→? · high · triaged:75e17b4cc1c9a51e03782bae8878edc5a62c954f · schema:2

[CCR-20260916-258] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20260916-259] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-260] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-262] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-261] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Resolution — PR #258 (work item #249)

Status: RESOLVED — all three trusted review findings are resolved on 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c. Their valid dispositions were assigned in the earlier triage at 75e17b4cc1c9a51e03782bae8878edc5a62c954f and remain frozen. This pass made no additional code changes; it reverified the fixes and reviewed the one-commit test-only delta from that trusted base.

Findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

Path: scripts/profile_config.py.

The fix in 75e17b4cc1c9a51e03782bae8878edc5a62c954f preserves the empty-config behavior for a nonexistent explicit path, allowing confirmed write --config <new path> to create it. test_explicit_new_config_path_can_be_created passed in the focused profile-config suite.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

Path: docs/configuration.md.

The documentation update in 75e17b4cc1c9a51e03782bae8878edc5a62c954f describes the shared configuration fallback for profile_config.py and stats.py, including their stderr/stdout behavior.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

Path: scripts/profile_config.py.

The fix in 75e17b4cc1c9a51e03782bae8878edc5a62c954f resolves and follows a symlinked configuration target while preserving the link. The focused profile-config suite, including the linked and main worktree symlink cases, passed.

Verification

Agent-reported local results:

  • python3 -m unittest discover -s tests -p 'test_profile_config.py' -q — passed, 34 tests.
  • python3 -m unittest discover -s tests -p 'test_stats.py' -q — passed, 42 tests.
  • python3 -m unittest discover -s tests -q — interrupted while entering test_run_cycle.py setup (exit 130); no result claimed.
  • timeout 90s python3 -m unittest discover -s tests -v — reached the 90-second cap (exit 124); no assertion failure appeared in the observed output, but the full suite did not complete.
  • Delegated cc-code-review of 75e17b4cc1c9a51e03782bae8878edc5a62c954f..7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c — no findings. The delta only normalizes path expectations to resolved paths in two test files.
  • Boundary verification: not required; this pass changed no runtime code and the affected CLI behavior is exercised by the focused suites.

Checks of the pushed head

Head: 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c — 4 passed, 2 failed, 0 pending.

  • Passed: Skills, manifests, and Bash installer; Windows test shards windows-1, windows-2, and windows-3.
  • Failed: Windows test shard windows-4; PowerShell installer.

Per the parallel CI policy for this stage, these check results are recorded for the cycle CI gate; no in-stage CI fix round was run.

The review delta and this pass's verification introduced no security-sensitive code changes.

@datacas

datacas commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner Author

[CCR-20261016-263] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Rereview — PR #258 (work item #249), current head after fixes

Status: REVIEW_PASSED_AWAITING_CI — reviewed head 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 501-line accumulated diff was read (SHA-256 c944b664…ca25a confirmed). Previous reviewed head: 75e17b4cc1c9a51e03782bae8878edc5a62c954f. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md. This is a completed review of this head, not an approval; the CI gate waits for the checks.

What changed since the previous review

75e17b4..7cd4ade touches only tests/test_profile_config.py and tests/test_stats.py (path assertions compare .resolve() forms). No product code changed.

Previous findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

Re-verified on this head in a disposable repo: write --config R/main/new.yml --preset single-anthropic --no-probe --confirmed → exit 0, file created; show --config R/main/missing.yml → exit 0 with built-in defaults. Covered by test_explicit_new_config_path_can_be_created.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

docs/configuration.md:19 and :273 now cover the main-worktree fallback, stderr reporting, explicit new --config paths, and symlink handling for profile_config.py and stats.py.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

Re-verified: main .code-cycle.yml symlinked to a file outside the repo; write --cwd <linked> → exit 0, the real file gained profiles, the symlink is intact, nothing created in the linked worktree. A foreign --config from the linked worktree → exit 1 naming the expected path, file untouched. stats.py --cwd <linked> → exit 0 with the configuration: line on stderr, JSON on stdout.

New findings

None.

Security triage

.code-cycle.yml declares no security_review.always_when rule; defaults applied: no auth, session, secrets, dependency, workflow or deployment path changed (the fix delta is tests only). Not a sensitive change: the security audit was skipped after triage. My own reading of the write boundary in _validate_write_target found no confirmed vulnerability.

Verification executed

  • python3 -m unittest discover -s tests -q: 1475 tests, OK (exit 0); working tree unchanged afterwards.
  • test_profile_config.py 34 tests OK; test_stats.py 42 tests OK.
  • Runtime repros above (REV-001, REV-003, foreign target, stats from a linked worktree).
  • Not run: Windows locally; a separate cc-verify pass (checks were executed directly).

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

gh pr checks 258 on 7cd4ade: 4 passed, 2 failed, 0 pending.

  • Passed: Skills, manifests, and Bash installer; Windows test shard (windows-1), (windows-2), (windows-3).
  • Failed: Windows test shard (windows-4) — the log shows test_profile_config.LinkedWorktreeConfigTests.test_write_reports_a_symlink_loop_without_a_traceback returning exit 0 where 1 was expected (tests/test_profile_config.py:191); the only failure in 739 tests. PowerShell installer — fails in its "Require all Windows test shards to pass" step, i.e. as a consequence of windows-4.

State only, not a finding; the CI gate decides what the failed shard means for the next resolution.

Residual risk

The self-referencing symlink handling in _validate_write_target behaves differently on Windows in CI than on Linux (the write is not rejected); this review does not establish whether the test or the product behaviour should change. resolve_config runs git rev-parse twice per call (minor).

Verdict

No open finding blocks approval. REVIEW_PASSED_AWAITING_CI — required checks of this head have not all passed.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-rereview","status":"REVIEW_PASSED_AWAITING_CI","issue_provider":"github","issue_id":"249","code_host":"github","change_request_id":"258","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/258","pr_number":258,"issue_number":249,"comment_url":"https://github.com/datacas/code-cycle-toolkit/pull/258#issuecomment-6219853152","previous_reviewed_head_sha":"75e17b4cc1c9a51e03782bae8878edc5a62c954f","reviewed_head_sha":"7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c","head_sha":"7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c","review_run_id":"CCR-20261016-263","reviewer":{"profile":"reviewer","provider":"anthropic","model_requested":"claude-sonnet-5-5","model_resolved":null,"effort":"high"},"verified_findings":[{"id":"REV-001","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-002","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"},{"id":"REV-003","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"}],"new_findings":[],"blocking_findings":[],"checks":{"head_sha":"7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c","passed":4,"failed":2,"pending":0},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

Resolution — PR #258 (work item #249)

Status: RESOLVED on 74c19250692d051f110aa37cdf7c68d858180465. The fix addresses the failed checks reported on reviewed head 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c; the checks remain separate from the review findings. The three review findings remain resolved with their previously frozen valid dispositions.

[CCT-20261016-003] · cheap_coder · openai/gpt-6-luna→? · high · triaged:7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c · schema:2

[CCR-20260916-258] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20260916-259] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-260] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-262] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-261] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

[CCR-20261016-263] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Review findings (unchanged by this check resolution)

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

The two failed checks on 7cd4ade were diagnosed from their GitHub logs. Windows test shard (windows-4) failed because test_write_reports_a_symlink_loop_without_a_traceback expected exit 1 but got 0 on Windows. The PowerShell installer failure was downstream: its “Require all Windows test shards to pass” step failed because that shard failed. The in-scope cause was non-strict Path.resolve() accepting the self-referencing symlink on Windows, after which the atomic write replaced it.

Changed _validate_write_target in scripts/profile_config.py to resolve symlink targets strictly (including the linked-worktree expected target). A loop or dangling symlink now takes the existing controlled ProfileConfigError path consistently; regular new-file targets remain non-strict. Commit: 74c19250692d051f110aa37cdf7c68d858180465.

Verification

Agent-reported verification: python3 -m unittest tests.test_profile_config.LinkedWorktreeConfigTests -v passed (8 tests); python3 -m unittest discover -s tests -q passed (1475 tests); a real CLI invocation against a self-referencing config symlink returned exit 1, printed the controlled error without a traceback, and preserved the symlink. git diff --check passed. CI uses Windows and Python 3.14; local verification used Linux and Python 3.10.12 with PyYAML 5.4.1, so the Windows-specific path behavior was not locally executed. The complete fix delta was reviewed from trusted base 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c; no findings. Security review of this symlink write-boundary change found no confirmed vulnerabilities.

Checks of pushed head

Read once from GitHub for 74c19250692d051f110aa37cdf7c68d858180465 under the parallel CI policy: 0 passed, 0 failed check runs, 5 queued. The workflow also defines PowerShell installer, but it was not present in this snapshot and is reported as an expected missing gate. No wait or CI fix round was run.

@datacas

datacas commented Oct 16, 2026

Copy link
Copy Markdown
Owner Author

[CCR-20261016-264] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Rereview — PR #258 (work item #249), after the symlink-loop fix

Status: REVIEW_PASSED_AWAITING_CI — reviewed head 74c19250692d051f110aa37cdf7c68d858180465 (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 507-line accumulated diff was read (SHA-256 3b37a181…25d92a confirmed). Previous reviewed head: 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md. This is a completed review of this head, not an approval; the CI gate waits for the checks.

What changed since the previous review

7cd4ade..74c1925 changes only _validate_write_target in scripts/profile_config.py (+9/−3): resolve(strict=…) is used when the target (or, in a linked worktree, the expected path) is a symlink, so symlink loops and dangling links raise the handled ProfileConfigError on every platform instead of being replaced by the atomic write. This targets the earlier windows-4 failure (test_write_reports_a_symlink_loop_without_a_traceback).

Previous findings

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

Re-verified on this head in a disposable repo: write --config main/new.yml --preset single-anthropic --no-probe --confirmed → exit 0, file created; show --config main/missing.yml → exit 0 with defaults; an explicit --config write succeeds while an unrelated default config is a symlink loop.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

No change since the last review; docs/configuration.md:19 and :273 document the fallback, stderr reporting, explicit new paths and symlink handling.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

Re-verified after the strict-resolve change: main .code-cycle.yml symlinked to a file outside the repo; write --cwd <linked> → exit 0, the real file gained profiles, the symlink is intact, nothing created in the linked worktree. A foreign --config from the linked worktree → exit 1 naming the expected path, no file written.

New findings

None. Observed behaviour of the new strictness (intended per the commit message): a symlink loop → exit 1 cannot resolve configuration write target …: Symlink loop from both the main and the linked worktree; a dangling symlink → exit 1 [Errno 2] No such file or directory, nothing created at the link target.

Security triage

.code-cycle.yml declares no security_review.always_when rule; defaults applied: no auth, session, secrets, dependency, workflow or deployment path changed. Not a sensitive change: the security audit was skipped after triage. My own reading of the write boundary in _validate_write_target found no confirmed vulnerability; the change only makes it stricter.

Verification executed

  • python3 -m unittest discover -s tests -q: 1475 tests, OK (exit 0); working tree unchanged afterwards.
  • Runtime repros above (REV-001, REV-003, loop, dangling link, foreign target).
  • Not run: Windows locally; a separate cc-verify pass (checks were executed directly).

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

gh pr checks 258 on 74c1925: 5 passed, 0 failed, 1 pending. Passed: Skills, manifests, and Bash installer; Windows test shard (windows-1), (windows-2), (windows-3), (windows-4) (previously failing; now pass). Pending: PowerShell installer. 0 failed. State only, not a finding; the CI gate decides.

Residual risk

Windows symlink behaviour is exercised only by CI; the shards now pass. resolve_config runs git rev-parse twice per call (minor).

Verdict

No open finding blocks approval. REVIEW_PASSED_AWAITING_CI — PowerShell installer has not passed yet.

ORCHESTRATION_RESULT (JSON)

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

@datacas

datacas commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner Author

[CCR-20261016-265] · reviewer · anthropic/claude-sonnet-5-5→? · high · schema:2

Earlier run lines on this change request are preserved: CCR-20260916-258, CCR-20260916-259, CCR-20261016-260, CCR-20261016-261, CCR-20261016-262, CCR-20261016-263, CCR-20261016-264.

Rereview — PR #258 (work item #249)

Status: APPROVED — reviewed head 74c19250692d051f110aa37cdf7c68d858180465 (equals the PR head) against merge base cad0b88b8b791b184a70e617ecaaae211ac65fd1. The 507-line accumulated diff was read in sections (SHA-256 3b37a181…25d92a confirmed). Previous reviewed head: 7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c. Convention applied: AGENTS.md (tool routing only); no CLAUDE.md. This pass verifies recovered attempt attempt-7a7250c88ad342b5b3fa09c2c721b4b8 by re-executing every claim instead of reusing its result.

Changed since the previous review

Only 74c1925 (symlink-loop handling in _validate_write_target, with tests). The earlier resolver fixes are unchanged.

Previous findings (dispositions frozen)

[REV-001] · medium · resolved · valid · blocks:yes — --config <new path> no longer creates a configuration file

Verified: profile_config.py write --config <new>.yml --confirmed exits 0 and creates the file; show --config <missing> exits 0 with defaults. Covered by test_explicit_new_config_path_can_be_created.

[REV-002] · low · resolved · valid · blocks:no — docs/configuration.md still describes only run_cycle.py fallback

Verified: docs/configuration.md lines 19 and 273 now name run_cycle.py, profile_config.py, and stats.py, the stderr report, and the explicit new-path behaviour.

[REV-003] · low · resolved · valid · blocks:no — Linked-worktree write guard rejects a symlinked main config

Verified in a disposable linked worktree: a write from the linked worktree follows the symlinked main config, keeps the symlink, and writes the target; a symlink loop exits 1 with cannot resolve configuration write target and no traceback; a foreign --config target is rejected (exit 1) and the main config is unchanged.

New findings

None.

Security triage

The change touches a filesystem write guard, so the write-target boundary was audited inline. cc-security-review was not delegated; this is the degraded path. Foreign target, symlink escape, symlink loop, and dangling-link cases all fail closed or stay inside the resolved repository config. No vulnerability found.

Verification

  • python3 -m unittest discover -s tests -p test_profile_config.py -q: 34 tests, OK.
  • python3 -m unittest discover -s tests -p test_stats.py -q: 42 tests, OK.
  • git diff --check <merge-base> HEAD: clean.
  • Direct CLI reproductions above (REV-001/003), plus stats.py --cwd <linked worktree>: exit 0, selected path on stderr, JSON on stdout.
  • Not run: the full 1,470-test suite (the CI shards below cover it).

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

All 6 checks on this head passed: PowerShell installer, Skills/manifests/Bash installer, Windows test shards 1–4. The base branch has no required-check protection, so these are every defined check. The failures reported on 7cd4ade no longer apply to this head.

Residual risk and verdict

Low. Every finding is resolved, none blocks approval, and every required check of this head passed.

ORCHESTRATION_RESULT (JSON)

ORCHESTRATION_RESULT
{"skill":"cc-rereview","status":"APPROVED","issue_provider":"github","issue_id":"249","code_host":"github","change_request_id":"258","change_request_url":"https://github.com/datacas/code-cycle-toolkit/pull/258","pr_number":258,"issue_number":249,"comment_url":"https://github.com/datacas/code-cycle-toolkit/pull/258#issuecomment-6220175029","previous_reviewed_head_sha":"7cd4ade6a9ae8d4d302c7d58f8725f24346e7a4c","reviewed_head_sha":"74c19250692d051f110aa37cdf7c68d858180465","head_sha":"74c19250692d051f110aa37cdf7c68d858180465","review_run_id":"CCR-20261016-265","reviewer":{"profile":"reviewer","provider":"anthropic","model_requested":"claude-sonnet-5-5","model_resolved":null,"effort":"high"},"verified_findings":[{"id":"REV-001","severity":"medium","blocks_approval":true,"status":"resolved","disposition":"valid"},{"id":"REV-002","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"},{"id":"REV-003","severity":"low","blocks_approval":false,"status":"resolved","disposition":"valid"}],"new_findings":[],"blocking_findings":[],"checks":{"head_sha":"74c19250692d051f110aa37cdf7c68d858180465","passed":6,"failed":0,"pending":0},"blocking":false}
END_ORCHESTRATION_RESULT

@datacas
datacas merged commit dc57efd into main Oct 17, 2026
6 checks passed
@datacas
datacas deleted the issue-249-shared-config-resolver branch October 17, 2026 14:38
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.

Resolve .code-cycle.yml from the main worktree in cc-profile-config and cc-stats

1 participant