Repository navigation
fix: prevent archive tests from leaking native filesystem mode - #154138
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs changes before merge. Reviewed September 20, 2026, 7:04 PM ET / 23:04 UTC. ClawSweeper reviewWhat this changesThe skill archive tests scope fallback filesystem mode to the read-failure operation and restore the original environment without leaving a programmatic override behind. Merge readiness⛔ Needs changes before merge - 1 item remains Keep open: this is a focused, source-supported repair that current main still needs. No introduced correctness or security defects were found; the documented flake-validation requirement remains outstanding. Priority: P2 Review scores
Verification
How this fits togetherSkill installation tests exercise archive extraction and file cleanup through fs-safe. Its process-wide configuration can affect later Claw artifact tests running in the same worker. flowchart LR
A[Archive fault test] --> B[Scoped environment helper]
B --> C[Filesystem mode selection]
C --> D[Archive extraction and cleanup]
D --> E[Restore prior environment]
E --> F[Later Claw artifact tests]
Before merge
Agent review detailsSecurityNone. PR surfaceTests -1. Total -1 across 1 file. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Keep filesystem fault configuration local to its test operation while preserving downstream tests’ ability to select their own mode. Do we have a high-confidence way to reproduce the issue? Yes: run the archive read/close fault cases before the Claw close-failure case in one native-capable worker. Source confirms the precedence leak and the body reports before/after results; this read-only review did not execute tests. Is this the best way to solve the issue? Yes: repairing the producer with the existing environment helper removes the persistent override without weakening the downstream assertion or changing production code. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 33f18c3dc131. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
Related: #154115
What Problem This Solves
Fixes the Claw artifact close-failure test failing when skill archive fault tests run earlier in the same worker.
User Impact
No production behavior changes. The skill tests stop leaving filesystem configuration behind for subsequent tests.
Why This Change Was Made
The archive read-fault test captured fs-safe's effective native mode, forced its fallback, then restored that effective value as a programmatic override. Restoring
autothis way prevented a later test's environment setting from selecting fallback mode, so its close-failure injection was bypassed.Scope the read-fault test's environment through the existing
withEnvAsynchelper instead. It restores the original value or absence without creating an override. All fault, close-count, publication, and cleanup assertions remain unchanged, including the Claw test that exposed the leak.Evidence
offbut effective mode isauto.off.git diff --checkpassed. Fresh independent review found no actionable issues through P2.23462b4048ec47e01264cba145f4323013be8f05matches the relevant source at this branch's base6e5a6c6c5a7c00feee802c997a35ee740c73bb9dbyte for byte. The original CI failure was on Node 24 with two workers; the controlled reproduction establishes the ordering mechanism on Node 26, not the historical worker assignment.The proof runner's final index-byte restoration check failed after the tests passed. Independent reconciliation verified all 47,080 staged mode/blob/path entries still match the base commit, both touched files have their original bytes, and the checkout has no staged or working changes. The original failed check was retained; tests were not rerun to suppress it.