Repository navigation
fix(examples): stop microphone capture between recordings - #4143
Conversation
Castiron custom codeEvaluated main: Trusted main policy: ✅ No new custom-code files detected. 42 mixed files remain; 0 existing customizations changed. Compared 42 existing customizations unchanged
2 more in the full report. A changed generated baseline means this report cannot reliably identify which handwritten lines changed. Inspect the custom-code diffDownload the exact patch produced by this run (requires repository access): gh run download 39665538865 --repo openai/openai-python \
--name castiron-custom-code-39665538865-1 --dir /tmp/castiron-custom-code-39665538865-1
git apply --stat /tmp/castiron-custom-code-39665538865-1/custom-code.patch
cat /tmp/castiron-custom-code-39665538865-1/custom-code.patchOr reproduce it from an SDK checkout containing the vendored reporter: git fetch --no-tags origin c99df7b87d214094eb819267575e06ecc8c7c71c e21bab2ceacff4df012d359e27933059e642bb4a
python3 scripts/castiron/custom_code_report.py report \
--base c99df7b87d214094eb819267575e06ecc8c7c71c \
--head e21bab2ceacff4df012d359e27933059e642bb4a --target-branch main --fetch --require-head-hash --public \
--out /tmp/castiron-custom-code-e21bab2ceacf
cat /tmp/castiron-custom-code-e21bab2ceacf/custom-code.patchThis is the current full custom patch for mixed files, not an attribution of only the handwritten lines changed by this PR. |
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. |
There was a problem hiding this comment.
Reviewed e21bab2 with an independent static review. No blocking issues found. Microphone capture starts only after recording is enabled and the connection is available; the flag is rechecked after waiting. Stop aborts/closes the stream, resume creates a fresh stream, and finally handles worker cancellation or start failure. Stream access has no await boundary between eligibility checks and reading, so the key handler cannot close the stream midway through a read on this event loop. Existing in-flight upload behavior is unchanged.
Hosted checks are complete; OkTest and validation checks pass, with conditional jobs skipped. No candidate code, tests, microphone capture, or live API session was executed locally.
Automated Release PR --- ## [3.36.1](openai/openai-python@v3.36.0...v3.36.1) (2026-10-22) ### Bug Fixes * **api:** honor per-call WebSocket query settings ([openai#4138](openai#4138)) ([d40a5e1](openai@d40a5e1)) * **examples:** stop microphone capture between recordings ([openai#4143](openai#4143)) ([26e5d92](openai@26e5d92)) * validate browser calls before reading driver state ([openai#4142](openai#4142)) ([2bfe460](openai@2bfe460)) ### Chores * **api:** clarify service-account API key deletion ([openai#4151](openai#4151)) ([6ed945e](openai@6ed945e)) ### Refactors * prepare handwritten chunked upload runtime ([openai#4146](openai#4146)) ([2d58e82](openai@2d58e82)) * prepare handwritten vector-store polling runtime ([openai#4148](openai#4148)) ([7cd7028](openai@7cd7028)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: openai-sdks[bot] <284451331+openai-sdks[bot]@users.noreply.github.com>
Keep the microphone lifecycle aligned with the K recording toggle in the Realtime push-to-talk example. Open a stream only when recording is enabled and the connection is ready, abort and close it when recording stops, and create a fresh stream on resume so queued samples do not carry into the next recording.
Validation: