Repository navigation
fix(deps): allow temporalio 1.35 and openai-agents 0.20 - #567
Merged
Merged
Conversation
temporalio 1.35 moves the OpenAI Agents integration into the temporalio-openai-agents package, which needs openai-agents 0.20+. Depend on it directly, raise openai-agents to >=0.20,<0.23 and openai to >=2.45,<4, and pass the now-required cache_write_tokens to InputTokensDetails. Update the templates and examples capped in #556. This lets consumers pick up temporalio 1.35's bundled Rust bridge with fixed rustls (>=0.23.46) and zip (>=9.0.5). Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Tutorial CI failed on this branch for two reasons: - uv run --with resolved each tutorial against the released agentex-sdk first, then overlaid the local wheel. Every released SDK caps openai-agents below 0.15, so the >=0.20 pins were unsatisfiable. The overlay also dropped tutorial extras, so 130_langgraph lost temporalio-langgraph on temporalio 1.35. - The Docker builds install agentex-sdk from PyPI, where no release allows temporalio 1.35 yet. run_agent_test.sh now resolves the tutorial and both wheels together (--no-project --with-editable .). The tutorial pins are wide again, so agentex-sdk picks the temporalio and openai-agents versions: the released SDK today, 1.35 once this ships. Co-Authored-By: Claude Opus 5.5 <[email protected]>
openai-agents changed its implicit default model from gpt-4.1 (0.14) to gpt-5.6-luna (0.20+). The new default writes a text preamble before calling tools, so 040_other_sdks stopped seeing the tool request message before the first agent text. Pin the model these tutorials were written and tested against. Co-Authored-By: Claude Opus 5.5 <[email protected]>
temporalio-openai-agents ships two incompatible sets: 1.0 needs openai-agents 0.20 with openai 2.x, and 1.1 needs openai-agents 0.22 with openai 3.x. The old ranges let a fresh install pick the 1.1 set, which neither uv.lock nor the test suite covers, and the 010_agent_chat tutorial stopped responding on it. Narrow the ranges to the 1.0 set. The locked versions don't change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Five slow retries can hit the 15-minute job timeout before the workflow's "Print agent logs on failure" step runs, so a timed-out tutorial left no agent logs to debug from. Co-Authored-By: Claude Opus 5.5 <[email protected]>
ModelSettings.to_oai_model_settings() used model_dump(), which writes
every unset Reasoning field as an explicit None. openai 2.45+ added
Reasoning.mode, context and generate_summary. After a Temporal activity
round-trip, the Responses API got {"reasoning": {"mode": null}} and
returned 400 ("Invalid type for 'reasoning.mode'"). That is why
010_agent_chat stopped responding. Rebuild Reasoning from its set
fields only, and add a regression test.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The narrowing wasn't the cause of the 010_agent_chat failure: the Reasoning null-field bug was (fixed in the previous commit). It also blocked consumers that need openai-agents 0.21+, so restore the >=0.20,<0.23 / openai <4 ranges. This reverts commit 2675ec7. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Use a nonzero cache_write_tokens in the usage fixture and assert it on the response, so a hardcoded zero would fail. Cover payloads where the field is missing or None. Co-Authored-By: Claude Opus 5.5 <[email protected]>
danielmillerp
approved these changes
Nov 9, 2026
Merged
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.
What changes
adk/pyproject.toml:temporalio>=1.26.0,<1.35becomestemporalio>=1.35.0,<2.temporalio-openai-agents>=1.0.0,<2.openai-agents>=0.14.3,<0.15becomesopenai-agents>=0.20,<0.23.openai>=2.2,<2.45becomesopenai>=2.45,<4. The<2.45cap only existed because openai-agents 0.14 could not buildInputTokensDetailson openai 2.45+.temporal_streaming_model.pypassescache_write_tokens, which openai 2.45 made a required field ofInputTokensDetails. It reads the value from the streamed usage and falls back to 0. Three test files get the same field.temporal-openai-agentsandsync-openai-agents-local-sandboxinit templates, five Temporal tutorials and the procurement demo now pintemporalio[openai-agents]>=1.35.0,<2andopenai-agents>=0.20,<0.23. These replace the pins added in fix(deps): cap temporalio below 1.35 #556.uv.lockchanges:Why
#556 capped temporalio below 1.35 because 1.35 moved the OpenAI Agents integration out of the core wheel. This PR is the follow-up #556 described. The integration now ships as
temporalio-openai-agents, which needsopenai-agents0.20 or later.temporalio.contrib.openai_agentsremains as a shim that re-exports the new package. With that package installed, the SDK's existing imports work unchanged.The cap also blocks dependency fixes. temporalio bundles a Rust bridge (
temporalio/bridge/Cargo.lock). 1.35.0 is the first release that shipsrustls>=0.23.46 andzip>=9.0.5. Whileagentex-sdkcaps temporalio below 1.35, projects that depend on it can't pick up those versions.Breaking changes reviewed
contribimports still resolve.TemporalIdGenerator.seed_span_id()andseed_trace_id(), and it rejects naive datetimes in typed search attributes. The SDK uses neither.gpt-5.4-miniin 0.16, thengpt-5.6-lunain 0.20. This only affects agents that don't set a model.cache_write_tokens.Checks
uv lock --checkpasses../scripts/lintpasses: ruff, pyright (0 errors), andimport agentex../scripts/check-slim-depspasses../scripts/teston Python 3.12: 1774 passed, 1622 skipped. The skipped tests need the mock server, which CI runs.OpenAIAgentsPluginandModelActivityParametersfromtemporalio.contrib.openai_agents, imports the worker, temporal client utils and plugin modules, and constructs the plugin.Release
This PR does not release anything. After merge, release-please adds a patch bump to its release PR.
🤖 Generated with Claude Code


Confidence Score: 5/5
The PR appears safe to merge; the previous test gap is addressed and no new blocking issue was found.Summary
Updates Temporal and OpenAI dependencies and adds the standalone Temporal OpenAI Agents package.
Reviews (12) · Last reviewed commit: "test: assert cache_write_tokens is copie..." · Reviewed by Greptile