fix(codex): combine Responses timeout fixes - #31938
Closed
wysie wants to merge 1 commit into
Closed
Conversation
Backports PR NousResearch#24126 and PR NousResearch#31855 onto the current helper-based agent loop. Preserves configured timeouts for Codex Responses requests, estimates non-stream stale timeouts from full Responses payloads, keeps xAI Responses extra_body preflight support, and adds regression coverage for the helper path. Co-authored-by: Hoang V. Pham <26063003+hehehe0803@users.noreply.github.com>
Contributor
|
Thanks @wysie — closing this as redundant. The Responses-payload stale-timeout estimation + The remaining gap — first-byte detection on the Codex stream itself — is being salvaged from #31984 in #32042. Appreciate you helping triage this. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Backports and combines two Codex Responses timeout fixes onto current
main:messages.This also resolves the current helper-based refactor conflict by applying the stale-timeout logic in
agent/chat_completion_helpers.py, while keepingrun_agent.pyas a forwarder. It preserves xAI Responsesextra_bodypreflight support while addingtimeoutto the allowlist.Test plan
git diff --check.venv/bin/python -m compileall -q run_agent.py agent/transports/codex.py agent/codex_responses_adapter.py agent/chat_completion_helpers.pyHERMES_HOME=/private/tmp/hermes-agent-test-home venv/bin/python -m pytest tests/agent/test_non_stream_stale_timeout.py tests/agent/transports/test_codex_transport.py tests/run_agent/test_run_agent_codex_responses.py tests/run_agent/test_run_agent.py::TestBuildApiKwargs -q -o addopts=Result:
140 passed, 1 warning.