47 model prices
  1. Home
  2. Releases
  3. OpenAI Agents SDK (Python)
  4. 0.24.0

OpenAI Agents SDK (Python) 0.24.0 release notes

OpenAI Agents SDK (Python) 0.24.0 was released on October 15, 2026. The latest version is 0.26.0.

v0.24.0 · · 92 listed changes

Release notes

0.24.0 (2026-10-15)

Key Changes

0.24.0 adds run-wide function error formatting and MCP discovery annotations, and improves recovery, sandbox safety, and tracing. This minor release includes compatibility changes for custom error callbacks and some saved agent graphs. Review the first two highlights before upgrading.

Highlights:

Thanks to @masasron for reporting the macOS local sandbox issue fixed in #5335.

Features
Bug Fixes
Release readiness review (v0.23.1 -> TARGET 0f44a46474d1f37a6b0ee006251a78bde4179bea)

This is a release readiness report done by $final-release-review skill.

Diff

https://github.com/openai/openai-agents-python/compare/v0.23.1...0f44a46474d1f37a6b0ee006251a78bde4179bea

Release intent
Release call

🟢 GREEN LIGHT TO SHIP. The prepared 0.24.0 candidate has no unresolved release blocker. Its compatibility changes have supported migration or fallback paths described below.

Scope summary
Risk assessment (ordered by impact)
  1. Route affected saved runs to their original SDK and agent code.

    • Risk: 🟢 LOW, with a required upgrade precaution. Some previously readable checkpoints now fail safely instead of risking incorrect agent ownership.
    • Evidence: the writer advances from schema 1.18 to 1.21. The reader rejects certain older graphs with same-name non-root agents whose saved identity ordering could have depended on hook attributes, even when those attributes remained unchanged. New identity generation excludes all hook instance attributes and retains the hook type. Graphs distinguishable only by those attributes cannot be serialized. Other supported historical schemas remain readable.
    • Files: src/agents/run_state.py, src/agents/_run_state_agent_identity.py, tests/test_run_state.py.
    • Action: finish affected legacy tasks with the original SDK, unchanged agent definitions, and hook ordering used when the snapshot was written. Use unique agent names before starting new durable runs. Do not rename a stored graph or change its schema label to force migration. Older SDKs cannot read new 1.21 snapshots.
  2. Update existing custom tool error formatters for a third category.

    • Risk: 🟢 LOW, with an explicit migration for exhaustive callbacks. A formatter that treats every non-rejection as a missing tool can now return misleading text for a crashed function.
    • Evidence: ToolErrorFormatterArgs.kind adds "tool_exception"; the optional error field is appended. The run-wide callback now handles eligible decorated function failures. Explicit per-tool handlers, including explicit None or the default handler, keep precedence. Factory-created MCP and Agent.as_tool failures, timeouts, cancellation, and schema-backed program calls keep their separate behavior.
    • Files: src/agents/run_config.py, src/agents/tool.py, src/agents/run_internal/tool_execution.py, tests/test_tool_exception_formatter.py.
    • Action: handle "tool_exception" explicitly or return None for it to retain the default message. Keep exception details out of model-visible output unless deliberately sanitized. With no custom formatter, default behavior stays unchanged.
  3. Preserve completed work without promising automatic replay.

    • Risk: 🟢 LOW. Recovery retains more completed work, but applications must still reconcile external side effects and partially committed history.
    • Evidence: deferred approval history waits for the output guardrail boundary. For client-managed runs, accepted call/output pairs survive sibling or callback failures after input and tool-output guardrails permit publication. Server-managed conversations retain their separate recovery path. Pending writes retain session identity and compaction state. Automatic compaction waits for pending approvals; standalone Redis replacement uses a transaction. Conversations writes use batches of at most 20 items and can commit partially across requests.
    • Files: src/agents/run_internal/session_persistence.py, src/agents/run_internal/tool_execution.py, src/agents/memory/openai_conversations_session.py, src/agents/memory/openai_responses_compaction_session.py, src/agents/extensions/memory/redis_session.py.
    • Action: resume supported nonterminal failures with the original session backend and ID, using returned state and history instead of replaying completed tools. After a partial Conversations append, inspect and repair remote history before retrying; do not resend the full list while an earlier part remains stored. Coordinate other writers; Redis atomic replacement does not prevent stale compaction across processes. Redis Cluster reads and pops remain available, but transactional append, clear, and replacement require a supported backend. Terminal output failures do not become replayable.
  4. Retain the intended sandbox, tracing, and display boundaries.

    • Risk: 🟢 LOW. macOS local commands can no longer launch host applications through Launch Services; disabled runs emit fewer spans inside caller-owned traces.
    • Evidence: #5335 adds Launch Services denial to the shared normal/PTY macOS profile. Native coverage checks the operating-system decision. Sandbox input validation returns recoverable tool errors without swallowing provider failures. Protected mount failures produce fresh redacted errors. Source arguments and linked exceptions remain intact, but the caught source traceback is detached. Tracing opt-out covers resumed tools and streamed cleanup, while resumed approved tools use the agent span. The realtime example renders tool content as literal text.
    • Files: src/agents/sandbox/sandboxes/unix_local.py, src/agents/sandbox/_mount_security.py, src/agents/run.py, src/agents/tracing/, examples/realtime/app/static/app.js.
    • Action: retain the macOS behavior note and #5335 reporter credit in the release. Do not describe local sandboxing as complete host or network isolation; use the documented Docker or hosted alternatives where needed. No tracing or realtime configuration migration is required.
  5. Keep additive integrations and dependency requirements explicit.

    • Risk: 🟢 LOW. Consumers opting into metadata, examples, or extras must use their specific contracts.
    • Evidence: converted MCP tools expose copied mcp_annotations metadata; it does not grant approval or become a model tool schema. Decisions examples use a separate OpenAI client with named typed answers and conservative refusal handling. Core Python support remains >=3.10 and the OpenAI dependency remains >=3.0.0,<4. The examples require OpenAI >=3.26.0,<4; the Temporal extra pins 1.34.0 and the Vercel extra accepts >=0.7.0,<0.9.
    • Files: src/agents/mcp/util.py, src/agents/tool.py, examples/decisions/, pyproject.toml, uv.lock.
    • Action: treat MCP annotations as untrusted discovery hints. Non-MCP and unannotated tools return None; reads return copies. Omitted hints stay omitted, so apply the installed MCP defaults yourself. The metadata is not serialized into tool origin. Install the example-specific SDK version and retain separate client/tracing ownership. Refresh application lockfiles when adopting the changed extras.
Documentation coverage (non-blocking)
File and section Wording or example to add
docs/human_in_the_loop.md, "Versioning pending tasks" and "Serialization options" Explain schema 1.21, the legacy hook-identity restriction, and finishing affected tasks on their original SDK/agent code. Recommend unique names for new durable runs; same-name agents indistinguishable without hook attributes cannot serialize. Explain that unserializable dataclass context is omitted with a warning; show a serializer/deserializer or context_override, and strict_context=True to reject omission.
docs/running_agents.md, tool_error_formatter; docs/tools.md, "Handling errors in function tools" Add tool_exception, error, callback migration, None fallback, explicit per-tool precedence, exclusions, and safe model-visible messages.
docs/results.md, failure recovery and pending input Explain retained completed outputs, absent custom output metadata after failed extraction, original session ownership, and the terminal-output replay limit. State that completed stop tools can reject added pending input; finish that run before starting a new user turn.
docs/sessions/index.md, Conversations, Redis, and compaction sections Document 20-item request batches and partial-append reconciliation. Multi-request writes disable client retries and drain the current request on cancellation; single-request writes retain client behavior. Explain deferred compaction during approvals; standalone Redis atomic replacement, Cluster write restrictions, and application coordination across writers.
docs/mcp.md, tool discovery and agent-level configuration Document FunctionTool.mcp_annotations as copied optional metadata; absent annotations return None and omitted hints remain omitted. Consumers apply the installed MCP defaults. State that metadata neither authorizes execution nor enters model schemas or serialized tool origin. Distinguish MCP failure handlers from the run-wide formatter.
docs/sandbox/clients.md, local and hosted clients Optionally note macOS Launch Services denial and document the Vercel >=0.7.0,<0.9 bound. Preserve the existing local-isolation limitations.

Source: GitHub release v0.24.0

Newer: 0.25.0Older: 0.23.1OpenAI Agents SDK (Python)