Skip to content

Deflake realtime handoff steering test#28300

Merged
felixxia-oai merged 1 commit into
mainfrom
codex/deflake-realtime-handoff-steering
Jun 15, 2026
Merged

Deflake realtime handoff steering test#28300
felixxia-oai merged 1 commit into
mainfrom
codex/deflake-realtime-handoff-steering

Conversation

@felixxia-oai

@felixxia-oai felixxia-oai commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • keep the realtime mock websocket open for the handoff steering test after scripted responses
  • avoid racing the mock server close before the standalone handoff append is observed, which was showing up as a Windows timeout in CI

Details:
Failures in samples seem to be caused by:

  1. The mock websocket sends conversation.handoff.requested.
  2. The mock immediately closes the websocket because start_websocket_server(...) defaults to close_after_requests: true.
  3. On Windows, that close often surfaces as os error 10053 / 10054.
  4. The realtime stream shuts down before the routed handoff finishes creating/steering the follow-up request.
  5. The test waits for the expected follow-up event and times out.

The PR changes only step 2: for this test, the mock websocket stays open after sending the scripted handoff event. The same handoff event is still sent, and the test still asserts the important steering behavior:

  1. first Responses request has the original prompt
  2. first request does not contain realtime delegation
  3. second Responses request does contain the realtime delegation

Validation

  • just fmt
  • just test -p codex-core --test all suite::realtime_conversation::inbound_handoff_request_steers_active_turn

Recent CI failures with the same signature

@felixxia-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor

Codex Review: Didn't find any major issues. Breezy!

Reviewed commit: 7b622835b8

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@felixxia-oai
felixxia-oai marked this pull request as ready for review June 15, 2026 13:23
@felixxia-oai
felixxia-oai requested a review from a team as a code owner June 15, 2026 13:23
@felixxia-oai
felixxia-oai merged commit db8927a into main Jun 15, 2026
31 checks passed
@felixxia-oai
felixxia-oai deleted the codex/deflake-realtime-handoff-steering branch June 15, 2026 22:50
@github-actions github-actions Bot locked and limited conversation to collaborators Jun 15, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants