Skip to content

fix(repair): resolve containment worker before isolation - #590

Merged
hxy91819 merged 1 commit into
mainfrom
fix/containment-worker-path
Jul 15, 2026
Merged

hxy91819 merged 1 commit into
mainfrom
fix/containment-worker-path

Conversation

@hxy91819

Copy link
Copy Markdown
Member

Summary

  • resolve the trusted containment worker path before changing the child process working directory
  • add regression coverage that rejects the relative worker invocation

Root cause

The repair containment preflight launched dist/repair/contained-command-worker.js as a relative path while setting the child cwd to the isolated work directory. Node therefore searched inside that temporary directory and failed with MODULE_NOT_FOUND before review or repair execution could start.

Impact

Repair jobs can reach the existing containment preflight again. The isolation policy, namespace and Landlock setup, capability dropping, network restrictions, writable roots, execution gates, and fail-closed checks are unchanged.

Validation

  • autoreview (--mode uncommitted): clean, no actionable findings
  • focused containment regression test: 6 passed
  • related containment and target-validation tests: 149 passed, 3 capability skips
  • unit tests: 1174 passed, 1 platform skip
  • pnpm run build:repair
  • build/lint portions of pnpm check
  • pnpm run format:check
  • git diff --check

The workflow preflight no longer fails on the worker module path locally. This container lacks the required Landlock/namespace capability, so hosted Linux remains the environment for the complete containment probe.

@hxy91819
hxy91819 marked this pull request as ready for review July 15, 2026 09:13
@hxy91819
hxy91819 requested a review from a team as a code owner July 15, 2026 09:13
@hxy91819
hxy91819 merged commit c17589a into main Jul 15, 2026
8 checks passed
@hxy91819
hxy91819 deleted the fix/containment-worker-path branch July 15, 2026 09:17
azaj01 pushed a commit to azaj01/clawsweeper that referenced this pull request Sep 21, 2026
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.

1 participant