pypi openai-agents 0.21.0
v0.21.0

6 hours ago

Key Changes

This minor release does not introduce a known breaking SDK behavior change. The minor version bump is for the new provider-neutral testing APIs and the OpenAI Python v3 compatibility update.

Highlights:

  • Added agents.testing, agents.realtime.testing, and agents.voice.testing utilities for deterministic Agent, Sandbox, Realtime, and Voice workflow tests without provider requests.
  • Updated OpenAI provider compatibility to openai>=3.0.0,<4, including HTTPX2-aware request, response, transport, and exception handling.
  • Hardened RunState interruption snapshots, recursive agent-tool approvals, max-turn finalization, streaming cleanup, and sensitive-error redaction.
  • Improved MCP lifecycle snapshot isolation and added configurable retry backoff ceilings.
  • Added Sandbox Runloop existing-secret support and tightened view-image path grants.
  • Added stricter Voice validation for invalid channels, frame rates, incomplete multichannel frames, and non-finite audio rates.

What's Changed

  • feat: support OpenAI Python 3 and HTTPX2 by @seratch in #4380
  • feat: add scripted model test utilities by @seratch in #4362
    • fix: freeze public testing module contracts by @seratch in #4386
    • fix: freeze public testing API state contracts by @seratch in #4404
    • fix(core): preserve scripted annotation streaming across Python SDK releases by @apcha-oai in #4422
  • fix(core): isolate interruption results by @hsusul in #4384
  • fix(core): close the model stream when a streamed turn ends in a terminal failure by @Luccacvb in #4366
  • fix(core): redact tool output value from output-type validation errors by @hsusul in #4396
  • fix(core): align Responses parallel tool calls with converted tools by @seratch in #4405
  • fix(core): max-turn handler session semantics by @seratch in #4412
  • fix(core): detach RunState interruption snapshots by @seratch in #4409
  • fix(core): isolate RunState checkpoint tool decisions by @seratch in #4413
  • fix(core): resume recursive agent tool approvals by @seratch in #4414
  • fix(mcp): stop handing the tools cache to callers by @chinmayv095 in #4424
  • fix(mcp): protect manager lifecycle state snapshots by @seratch in #4407
  • fix(mcp): isolate manager lifecycle results by @hsusul in #4368
  • fix(mcp): add configurable retry backoff ceiling by @seratch in #4379
  • fix(realtime): handle non-finite audio rates by @hsusul in #4419
  • fix(sandbox): expose the scripted sandbox session type by @seratch in #4406
  • fix(sandbox): apply stacked anchors sequentially by @seratch in #4369
  • fix(sandbox): snapshot HTTP proxy headers by @hsusul in #4397
  • fix(sandbox): snapshot per-op audit policies by @hsusul in #4398
  • fix(sandbox): honor view_image extra path grants by @sylvesterkaczmarek in #4417
  • fix(sessions): handle zero conversation history limits by @hsusul in #4365
  • fix(voice): honor WAV sample width by @FU-max-boop in #4361
  • fix(voice): reject incomplete multichannel audio frames by @seratch in #4370
  • fix(voice): reject non-positive audio channels by @hansu650 in #4372
  • fix(voice): reject non-positive audio frame rates by @hsusul in #4382
  • fix(voice): stop buffering audio when audio tracing is disabled by @rxits in #4411
  • fix(extensions): gate AnyLLM parallel tool calls on converted tools by @weivwang in #4363
  • fix(extensions): preserve resume argument ordering by @viyatb-oai in #4400
  • fix(extensions): let managed_secrets reference existing Runloop secrets by @xumaple in #4378

Documentation & Other Changes

New Contributors

Full Changelog: v0.20.0...v0.21.0

Don't miss a new openai-agents release

NewReleases is sending notifications on new releases.