Skip to content

test(dev): wait for the PTY size line instead of asserting it after ready - #858

Merged
ScriptedAlchemy merged 1 commit into
mainfrom
fix/pty-size-race
Sep 25, 2026
Merged

ScriptedAlchemy merged 1 commit into
mainfrom
fix/pty-size-race

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Summary

Verify (integration-1, Node 26) failed on b038e1a (run 36178852750) in host-session-pty.test.ts with expected 'ready\r\n' to match /24\s+80/u. The test polled until ready arrived, then asserted synchronously that the stty size line was already in the buffer. A PTY can deliver the two lines in separate chunks, so the assertion raced the second chunk.

The test now polls for ready followed by the size line.

Verification

  • rstest --config rstest.integration.config.ts packages/agent-bundle/tests/host-session-pty.test.ts passes 3/3 runs.
  • pnpm test: unit 4296/4296, route-unit 91/91, projection 197/197, integration 1161/1165 with the PTY test passing. The 4 integration failures are Workbench Playwright timing assertions (audiobook-curator acceptance, examples-real host-test and worktree-proximity, streaming-render Suspense fallback). This change cannot reach them. The same tests failed in the local run for test(rstest): run the win32 rename mock test in an isolated pool #857 on a host at load average 120 to 180, and they pass in hosted CI.

@ScriptedAlchemy
ScriptedAlchemy merged commit a81b9ae into main Sep 25, 2026
@changeset-bot

changeset-bot Bot commented Sep 25, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 0b4d810

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 25, 2026 •

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 ✅ Completed 2026-09-25T21:08:18.712913Z 0b4d810 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.

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