Fix bridge CI races in cancellation, deadlines and process tracking - #43
Open
hetaoBackend wants to merge 4 commits into
Open
hetaoBackend wants to merge 4 commits into
hetaoBackend wants to merge 4 commits into
Conversation
…iers Assisted-by: codex-cli reason:post-merge-ci-rejection-race Docs-Impact: Test synchronization only; runtime behavior is unchanged.
Assisted-by: codex-cli reason:ci-startup-timeout-diagnosis
Register a deterministic deadline check after the trace handle opens, while keeping the end-to-end absolute-budget and no-worker assertions. Export the existing setup helper without changing its runtime behavior. Assisted-by: codex-cli reason:windows-ci-phase-timing
Capture visible child identities while the original parent can still be revalidated. Preserve fail-closed behavior for unknown children and recycled parent PIDs, avoiding evidence loss when short-lived Git helpers exit during later task reads. Assisted-by: codex-cli reason:linux-containment-race
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem and resulting behavior
Shared CI exposed three races in CLI Agent Bridge:
assert.rejects, producing an unhandled rejection. The three CAS fixtures now register the assertion before releasing the asynchronous barrier and await the same assertion afterward.The cross-process serialization fixture also surfaces early delegation errors instead of obscuring them with a missing-start-event timeout. No test is skipped or converted into a retry-until-success gate.
This is separate from merged Dynamic Workflow #42 and changes only CLI Agent Bridge.
Validation
/tmpand the diagnostic container, not committed code.unpack-objects, and a separate minimal reproduction identifies automatic maintenance as another trigger. These helpers exit successfully before the tracker can bind their identities; the original parent then disappears, correctly preserving fail-closed quarantine. Immediate identity capture reduces an avoidable window but cannot guarantee observing arbitrary short-lived descendants. Thirty subsequent composite passes and fifty isolated passes do not prove this limitation fixed. The current Windows-only production support remains unchanged. A minimal directrunCommand+ real Git pull probe also reproduces without MCP or workspace lease handling. Resolving the residual CI flake requires an explicit test-boundary or containment design decision; this PR is not ready to merge on green CI alone.npm run check: 493 tests, 473 passed, 20 skipped, 0 failures. Exact-headdb62086Ubuntu validation, Windows Bridge, and CodeQL checks all passed. Those green checks do not supersede the remaining repeated-run evidence above.Failure evidence