Repository navigation
Unit flakes in shard 2/4: the ipc artifactScope case's spawn order, the grid live-count case's shared arm - #368
Merged
Merged
Conversation
… the parent is up, not on spawn order session.launch answers before its process spawns (EngineSession.run loads the session's state first), so the parent's and the thread's launches, both in flight, spawned in either order, and the case's queue handed the parent's transport to whichever spawned first. When the thread won, the parent's artifact_create ran as the thread and the thread's artifact_read ran as the parent, whose lineage holds no "dash": the refusal `artifact_read: no artifact "dash" in this session` reached JSON.parse as `Unexpected token 'a', "artifact_r"...`. Under load the old order failed 50 of 450 repeats; the case now waits for the parent's ready before launching the thread, and passed 450 of 450. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
…es its project The suites' Registry armed one org-wide flag that the next summary report of any project consumed. Reports of earlier cases' projects (a lease lapsing after its machine closed, a retry) keep reaching the Registry during the grid's live-count case, so one of them could take the arm before the case's own report; that report was then taken with `live`, the frame `working: 1, live: 0` never came, and the case failed listing other projects' summaries. The arm is now kept per project (`nextSummaryAsPrevious(project)`), and other projects' reports pass as they are. Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
SSFSKIM
added a commit
that referenced
this pull request
Oct 30, 2026
…d live-count row closed, the IPC item of the 2026-10-28 unit-flakes row dropped Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
SSFSKIM
added a commit
that referenced
this pull request
Oct 30, 2026
…les) Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
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.
Two unit cases that failed intermittently in class 1a, always in unit shard 2/4 and on branches that don't touch either file. Both files sit in shard 2/4 because vitest assigns files to shards by the SHA-1 of their path, so the shard is where they land, not a shared cause. Load makes both races more likely, but the two causes are separate.
src/engine-host/ipc.test.ts: the artifactScope caseCause.
session.launchanswers before its process spawns:EngineSession.runawaitsloadState()(several fs reads) beforeopts.spawn(plan)(src/engine-host/session.ts). The case launched the parent and the thread back to back and gave out transports from a queue in spawn order. When the thread spawned first,parentTbelonged to the thread andthreadTto the parent.artifact_createthen ran as the thread, andartifact_readran as the parent, whose lineage has no"dash". The refusalartifact_read: no artifact "dash" in this sessionreachedJSON.parseasUnexpected token 'a', "artifact_r"....Fix. The case waits for the parent to be ready before it launches the thread, as the file's other multi-session cases already do.
Evidence.
loadKeepback by 50 ms fails master's case with the exact CI error and passes the fixed one.apps/desk-hub/test/session-plane.test.ts: the grid's live countCause. The suites' Registry seam
nextSummaryAsPrevious()set one org-wide in-memory flag, which the next summary report from any project consumed (test/support/worker-under-test.ts). Earlier cases' projects keep reporting during this case (a lease that lapses after its machine closed, an unacknowledged report's retry). When one of those reports reached the Registry first, it took the arm, and the case's own report was taken withlive. The awaitedworking: 1, live: 0frame never came. The CI failures show exactly this: the case's own project arrives asworking: 1, live: 1next to other projects' summaries.Fix. The arm is kept per project in the Registry's kv (
summary-as-previous:<project>, armed withnextSummaryAsPrevious(project)), and other projects' reports pass through unchanged.Evidence. A reproducer reports another project to the Registry between the arm and the case's own report:
working: 1, live: 1.Gate
Class 1a (static, unit, probes on the pool) was green on the first attempt for head a161480 (tree 2313b0af2): run 41011792774. An independent review (
doperpowers:reviewer-medium) had no material findings.Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)