Repository navigation
One multi-turn smoke script for all three operating systems - #9086
Conversation
The check ran inline in the Linux, macOS and Windows smoke workflows as three copies of the same script, and being three copies is how one of them stopped checking. On 2026-05-22 an unrelated event-loop fix (#5669) turned the Linux copy's determinism assertion into a printed warning. macOS and Windows kept it, and are otherwise identical in logic: diffed, the only differences are that warning and some comments Windows had dropped. Nothing compared the three, so for three months the leg that runs on every pull request was the one not asserting, while the two that still asserted run rarely. The script moves to .github/scripts/studio_smoke/multi_turn_chat.py and all three call it. Nothing in it was platform specific; the only thing that differed per caller is the port, which it already read from BASE_URL. That removes 264 lines of YAML heredoc. It reads no environment and imports no SDK at module level, so the checking half is importable, and the new tests exercise it rather than grepping it: divergence between the two runs raises, trailing whitespace alone does not, an empty reply raises, and a transcript with no history grounding raises. Reverting the script to the warning form fails one of them; re-inlining a copy into a leg fails two. Worth stating plainly: this re-enables on Linux an assertion that has not run there since May. If greedy decoding is genuinely not reproducible on that leg, it will now fail rather than print. That is the right way round, and it will be one failure in one place rather than three copies to reconcile. The guard runs from workflow-trigger-lint.yml, which carries no paths filter, because a pull request that re-inlines one leg edits a workflow and nothing else.
|
@codex review |
|
Codex Review: Didn't find any major issues. Already looking forward to the next diff. Reviewed commit: ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ad5e1cc9e8
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| def check(label: str, first: list[str], second: list[str]) -> None: | ||
| for i, (a, b) in enumerate(zip(first, second), start = 1): | ||
| print(f"[{label} turn {i}] {a!r}") | ||
| assert a, f"{label}: empty turn {i} response" |
There was a problem hiding this comment.
Reject an empty reply from the second run
When the second greedy run returns no text while the first returns only tolerated whitespace (for example, "\n" versus ""), this assertion succeeds and the stripped comparison also succeeds, so the smoke test prints OK despite an empty second response. The previous Linux inline check explicitly asserted b, while the new unit test only covers an empty first response; validate the second reply before comparing the two runs.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Correct, and it is a regression I introduced in the consolidation rather than something either copy had. The Linux version asserted both replies; the macOS version I took the strict determinism check from asserts only the first, and I kept that half along with it.
The pair you name is exactly the blind spot: "\n" against "" strips to "" on both sides, so the comparison passes and the smoke test prints OK for a server that stopped answering halfway through.
Fixed in eb6f0e6. The test now covers an empty second run and that specific whitespace-against-nothing pair; dropping the new assertion fails it.
The stripped comparison cannot tell the two apart: a second run returning "" against a first returning "\n" compares EQUAL, so a server that stopped answering halfway through printed OK. The Linux copy asserted both before this was consolidated; the macOS copy it was taken from asserted only the first, and I kept that half. The test now covers an empty SECOND run and the exact whitespace-against-nothing pair the comparison is blind to. Dropping the new assertion fails it.
|
@codex review |
|
Codex Review: Didn't find any major issues. Bravo. Reviewed commit: ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |
The multi-turn chat check ran inline in
studio-inference-smoke.yml,studio-mac-inference-smoke.ymlandstudio-windows-inference-smoke.ymlas three copies of the same script. Being three copies is how one of them stopped checking.What the copies had done
On 2026-05-22, an unrelated event-loop fix (#5669) turned the Linux copy's determinism assertion into a printed warning:
macOS and Windows kept the assertion. Diffed against each other, those two are identical in logic; the only differences across all three are that warning and a few comments Windows had dropped. Nothing compared them, so for three months the leg that runs on every pull request was the one not asserting, while the two that still asserted run rarely.
The same shape shows up elsewhere in the triple: each leg now asserts things the others do not (
finish_reason == "tool_calls"only on Linux,status2 == 200only on macOS). Those blocks have diverged much further and are not touched here.What this does
.github/scripts/studio_smoke/multi_turn_chat.py; all three legs call it. Nothing in it was platform specific, and the only thing that differed per caller was the port, which it already read fromBASE_URL. Removes 264 lines of YAML heredoc.The tests
tests/studio/test_smoke_workflows_share_one_script.pyexercises the check rather than grepping it: divergence between the two runs raises, trailing whitespace alone does not, an empty reply raises, and a transcript with no history grounding raises. Mutation tested both ways:test_a_divergent_second_run_is_a_failure_not_a_warningtest_every_leg_runs_the_shared_scriptandtest_no_leg_has_grown_its_own_copy_backIt runs from
workflow-trigger-lint.yml, which carries no paths filter, because a pull request that re-inlines one leg edits a workflow and nothing else, and no paths filter in the repo matches.github/workflows/**.One thing to be explicit about
This re-enables on Linux an assertion that has not run there since May. If greedy decoding at temperature 0.0 with a fixed seed is genuinely not reproducible on that leg, it will now fail rather than print a warning. That is the right way round, and it is better as one failure in one file than as three copies to reconcile afterwards.