Repository navigation
fix(mxc): bound termination and output drain cleanup - #1166
miketripblog wants to merge 2 commits into
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 real behavior proof before merge. Reviewed September 9, 2026, 8:19 PM ET / September 10, 2026, 00:19 UTC (Revision 5). ClawSweeper reviewWhat this changesBounds cleanup waits for sandboxed Windows commands, caps blocked termination workers at eight, and adds Windows process regression tests. Merge readiness⛔ Blocked before merge - 6 items remain This remains useful work: current main and the latest release retain the blocking paths. Both previously reported defects remain unresolved, and the supplied Windows process evidence does not satisfy the repository’s required MXC integration proof. Priority: P1 Review scores
Verification
How this fits togetherMXC runs approved Windows commands inside an AppContainer through wxc-exec. Its executor receives cancellation and process output, then returns command results to the Windows node. flowchart TD
A[Approved Windows command] --> B[AppContainer executor]
B --> C[wxc-exec launcher]
C --> D[Exit or cancellation]
D --> E[Bounded termination and output drain]
E --> F[Command result]
F --> G[Windows node]
Before merge
Findings
Agent review detailsSecurityNone. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep bounded cleanup and worker limits while capturing available output independently of line endings, with reliable descendant cleanup and current-head native MXC validation. Do we have a high-confidence way to reproduce the issue? Yes, source establishes the blocking termination and inherited-pipe paths; the supplied Windows runs exercise them. This read-only review did not execute a current-main reproduction. Is this the best way to solve the issue? Not yet: bounding cleanup in the existing executor is appropriate, but retaining line-based capture loses partial output at the new deadline, and the descendant test has a publication race. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 3edc9b1b5b6e. LabelsLabel 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
HistoryReview history (4 earlier review cycles)
|
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
Superseded by #1387 (fix(mxc): bound termination and output drain cleanup), rebuilt from current main with deterministic bounded-cleanup and final-output regression coverage. The replacement remains draft and blocked on non-skipping windows-wsl-mxc proof. |
Summary
This addresses NODE-2 in issue #1122. It intentionally does not close #1122 because that issue contains multiple findings.
Root cause
Cancellation could block synchronously in process-tree termination. The normal launcher-exit path could also wait indefinitely when a descendant retained inherited stdout or stderr handles. The first bounded-kill implementation could retain one dedicated worker per permanently blocked kill.
Change
Regression coverage
Validation
Current head:
bb12539epowershell.exe -NoProfile -ExecutionPolicy Bypass -File .\build.ps1: passed. Shared, CLI, WinNode CLI, SetupEngine, and WinUI built successfully; documentation validation passed for 46 Markdown files.dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore --filter FullyQualifiedName~Mxc: 200 passed, 7 environment-gated skips, 0 failed.dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore: 3,698 passed, 32 skipped, 4 failed. The four failures are unchangedExecReusableCommandBinderTestsfailures and all four reproduced on pristine basefc9add75in a detached temporary worktree.dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore: 2,469 passed, 0 skipped, 0 failed.python .\.agents\skills\autoreview\scripts\autoreview --mode local ...: clean, with no accepted or actionable findings after the concurrency and test-determinism fixes.The four base-reproduced Shared failures are:
CarrierPayloadWithExplicitRelativePath_IsNotTreatedAsAmbiguousAcceptedSpaceGrammar_MatchesRealCmdChildArgvAcceptedMultiElementTail_MatchesRealCmdChildArgvAcceptedTabGrammar_MatchesRealCmdChildArgvReal behavior proof
Current-head local Windows process regressions passed:
The descendant-retained-handle test launches a real Windows child process that inherits stdout and stderr handles after its parent exits. The parent result returned successfully inside the bound, and the test cleaned up the descendant.
Proof limitation
Gateway MXC E2E was not run because this task explicitly prohibited Gateway MXC E2E. It is not presented as passed. No Gateway, pairing, permission, credential, or Pavilion install path was used.
Security and capability impact
No new permissions, identity, pairing, network, sandbox, or command authority.