Skip to content

mawsd unit flakes: cli-prompt's shell outlives its tail; process.test's teardown retries ENOTEMPTY - #438

Merged
SSFSKIM merged 1 commit into
masterfrom
fix-mawsd-unit-flakes
Nov 1, 2026
Merged

SSFSKIM merged 1 commit into
masterfrom
fix-mawsd-unit-flakes

Conversation

@SSFSKIM

@SSFSKIM SSFSKIM commented Nov 1, 2026

Copy link
Copy Markdown
Owner

Two test-only fixes for src/mawsd unit flakes that keep failing unit 3/4. In 41346408018 (O7's p5-o7-m6) they cost two of its four attempts.

cli-prompt.test.ts. The provision pipe case timed out waiting for DONE. The output already held enrolled, EXIT=0 and the whole stty -a dump, so the command had finished. The only missing piece was the shell's last echo DONE. Linux's pty drops a child's last output at its exit (gate-offload Decision Log 20, the same fact behind the pty table's flood cases). Now the shell runs read -r _ after DONE, and a new finish() waits for DONE, sends a line and only then awaits the exit. The shell can no longer exit before its tail is read. All four cases use finish(), and assertions are unchanged.

process.test.ts. afterEach's rmSync(scratch, { recursive, force }) met ENOTEMPTY while a killed child was still writing in the directory. It now passes maxRetries: 10, retryDelay: 100, which Node's rmSync uses to retry ENOTEMPTY, EBUSY and EPERM. That meets the tech-debt tracker row of 2026-10-28's exit, and the row closes at landing.

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)

… Linux's pty cannot drop the output's tail at its exit (the provision pipe case timed out with EXIT=0 and stty read but no DONE, 41346408018); process.test's teardown retries rmSync on ENOTEMPTY (tracker row of 2026-10-28)

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-11-01T21:19:13.344683Z
We couldn’t complete this review. Comment @codex review to try again.
2a97703 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

SSFSKIM added a commit that referenced this pull request Nov 1, 2026
…rge e48e270: the teardown's rmSync retries ENOTEMPTY while the killed engine host finishes writing)

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
@SSFSKIM
SSFSKIM merged commit e48e270 into master Nov 1, 2026
SSFSKIM added a commit that referenced this pull request Nov 1, 2026
…432, O12 M11 #431, O7 M3 #433, O17's document #430, O7 M5 re-plan #434 and #436, #437, #438) into p5-o16

The WIRE retake: master is at WIRE_MINOR 19, so O16 takes 20. The comment keeps master's entries through (19); O16's
additions (M2, M5, M3b, M3c fix wave 2), named under (16) on the branch, now follow under (20). WIRE_CAPABILITIES is
master's list plus host.holder. The manifest is master's (minor 19) regenerated with pnpm wire:manifest at 20: against
master it adds commands.daemon.restartEngineHost, commands.host.handover and events.daemon.engineHandover, changes
O16's additive status and supervisor fields, and lists host.holder. routes.json auto-merged and its pin holds.

Conflicts, each resolved keeping both sides:
- src/shared/ipc/wire.ts: WIRE_MINOR 20 as above.
- src/shared/ipc/wire-manifest.json: master's, regenerated (above).
- src/shared/host/detached-transport.ts: O16's report() (the status ask before the link is reported) keeps its shape;
  O5 M5's socketFd joins the port it reports.
- src/shared/host/op-ledger.ts: the orphanAtOpen comment names the services', the endpoint's (O12 M11) and the engine
  host's (O16 M3c) ledgers; none opens without it now.
- src/mawsd/daemon.ts: O5 M5's session.removed listener and O16's tellEngineHandover side by side; at the stop, O5's
  cua socket close and cache watch end, then engineHandover.stop().
- src/mawsd/front.ts: FRONT_COMMANDS holds daemon.restartEngineHost and session.capabilities.
- src/mawsd/cli.ts: O16's sessionHostsLine and O5 M6's renderText.
- src/engine-host/launch.ts: O12 M11's MAWS_LAUNCHED_BY and O16's MAWS_HOLDER_SOCKET.
- src/services/spine-root.test.ts: FRONT_EVENTS holds session.capabilitiesChanged and daemon.engineHandover.
- test/support/mawsd-scene.ts: the stand-in's events hold O5 M5's session.status and O16's maws.pane.show and
  host.supervisorStatus.
- scripts/mawsd-pack.test.mjs: O16's two session host pack tests and O5 M6's two --render tests.
- devenv/validate.sh: the header names the session host check and the render runtime check; both run.

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
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