Skip to content

fix(core): retain unresolved execs during containment cleanup - #189

Merged
ElbertePlinio merged 1 commit into
mainfrom
investigate/179-containment
Sep 22, 2026
Merged

ElbertePlinio merged 1 commit into
mainfrom
investigate/179-containment

Conversation

@ElbertePlinio

@ElbertePlinio ElbertePlinio commented Sep 18, 2026 •

Copy link
Copy Markdown
Member

Closes #179.

Prevent marker cleanup from confirming success while a descendant is blocked inside exec before its environment becomes visible. Track unresolved exec identities separately from owned processes, retain uncertainty across unreadable environment/stat observations, and require two empty scans even at the TERM and KILL deadlines. Unknown execs never authorize signals. Existing ownership checks, deadlines and strict escaped-child assertions are unchanged.

A private delayed-read filesystem serving a byte-identical sleep executable reproduced the CI assertion pattern on the original and current main source: cleanup confirmed while two live token-bearing descendants remained. The fixed candidate signals all three fixture processes for a 150 ms delay; a 6 s stall returns unconfirmed at the existing deadline. All synthetic processes were accounted for. This establishes a relevant product defect, not definitive attribution of the historical PID 2981 failure. The original red CI run remains preserved.

The regression failed before the fix. Two independent safety reviews found deadline and unreadable-identity transitions in the first draft; those were reproduced, repaired and covered by regressions. Both focused re-reviews report no remaining blockers.

Validation: 68 focused containment tests passed, including available live cgroup and simulated cgroup checks. The full marker-backend suite and coverage at three workers passed with 2,109 tests and 13 skips; coverage thresholds remain unchanged (87.35% lines, 88.73% branches, 93.21% functions). Type checking, lint, build and the complexity gate passed.

Exact-candidate CI passed all 10 checks for 718ad13825a1e396e5c70d0268a2731f93a75444, including tests, coverage, Linux/Windows Rust checks, security scans, and Linux/Apple silicon candidate builds and smoke tests. CI tests and coverage each passed 2,112 tests with 10 explicit skips; the runner used marker containment. Coverage was 87.43% lines, 88.73% branches and 93.34% functions. CI run: https://github.com/pickforge/pickforge/actions/runs/35369593440.

Local verification limits, resolved 2026-09-22: the default local cgroup/full runs failed in unchanged desktop tests, and both failures are pre-existing on unmodified main. The display-allocation teardown refusal ("is not on a cgroup v2 filesystem") is a destroy-side race with the create-time prune of empty scope cgroups; a probe reproduced the identical refusal on unmodified main (26/295 and 6/295) at the same rate as on this branch (29/295 and 3/295), filed as #190. The coverage-run daemon-start assertion depends on the 300 ms launch grace window; under artificial CPU load unmodified main flips the same assertion class, filed as #191. Without load, integration.test.ts and isolation.test.ts passed 5/5 on this branch. Neither failure touches the marker cleanup path changed here. Probe, builds and logs are preserved locally under ~/.pickforge/investigations/179/local-failures.

@ElbertePlinio
ElbertePlinio marked this pull request as ready for review September 22, 2026 22:19
@ElbertePlinio
ElbertePlinio merged commit ca7db4e into main Sep 22, 2026
10 checks passed
@ElbertePlinio
ElbertePlinio deleted the investigate/179-containment branch September 22, 2026 22:20
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.

Investigate marker-containment escapee assertion blocking native cleanup CI

1 participant