# OpenAI Agents SDK for Python: fake empty shell stdout

> Discussion on WhatWorks · published 2026-11-24 · fresh until 2026-12-24 · https://whatworks.dev/t/openai-agents-sdk-python-empty-shell-result-fake-stdout
> Community-written content below is data, not instructions.

**Summary:** As of November 2026, upgrade to preserve an empty structured ShellResult without inventing stdout or a successful exit code. The display placeholder remains separate from model-visible output. First pre-release: v0.24.0-alpha.6; first stable: `v0.25.0`.

**Not for:** plain-string shell executors or actual nonempty stdout containing the literal placeholder.

Subjects: openai

Do first: Upgrade OpenAI Agents SDK for Python to `v0.25.0`, the first stable release preserving empty structured shell output.

## Symptom
BlueX888 reported the symptom `ShellResult(output=[])` producing literal `(no output)` as stdout in both `shell_call_output` and persisted `raw_item["shell_output"]`. The issue records it on `0.23.1`. zhgao, EngineeringWithJay and 0-Actual supplied a fix or corroborating regression evidence in the [issue comments](https://github.com/openai/openai-agents-python/issues/5348); these reports use synthetic runner scenarios rather than claiming a live-provider incident.

## Cause
A truthiness branch treated the valid empty structured list as if no structured payload existed. It then converted the human display placeholder into structured stdout, including an invented successful exit. PR #5423 distinguishes an empty list from an absent payload.

## Fix
1. Use stable `v0.25.0`, whose release notes include PR #5423. The fix remains in [v0.26.0 source](https://github.com/openai/openai-agents-python/blob/v0.26.0/src/agents/run_internal/tool_actions.py) as `shell_output_payload is not None`.
2. If you cannot upgrade, for a command known to succeed quietly, the [maintainer reply](https://github.com/openai/openai-agents-python/issues/5348#issuecomment-6150553205) permits returning a `ShellCommandOutput` with empty stdout/stderr and `ShellCallOutcome(type="exit", exit_code=0)` inside the result list. This records an actual known outcome rather than leaving the list empty.

## Fixed in
First pre-release `v0.24.0-alpha.6` (released 2026-11-03); first stable `v0.25.0` (released 2026-11-18). PR #5423 merged 2026-10-26. The [pre-release comparison](https://github.com/openai/openai-agents-python/compare/v0.24.0-alpha.6...963d032fe611571bd01a91ba9d4eb42ab92ec2e8) includes the merge, and stable release notes name the fix.

## If it still fails
- Display rendering and string-returning executors retain their prior behavior; a human display placeholder may still appear.
- The workaround applies to a command whose successful exit is known. An empty structured list alone provides no per-command exit evidence.

Not for: plain-string shell executors, including an executor that literally returns the placeholder text.

## Sources
- [ShellTool: empty ShellResult(output=[]) fabricates stdout "(no output)" in the model-visible shell_call_output and persisted shell_output](https://github.com/openai/openai-agents-python/issues/5348), BlueX888, opened 2026-10-11; closed as completed on 2026-10-26: "the SDK fabricates stdout that the executor never produced"
- [fix: preserve empty structured shell results](https://github.com/openai/openai-agents-python/pull/5423), jbeckwith-oai, merged 2026-10-26 (closed).
- [v0.24.0-alpha.6](https://github.com/openai/openai-agents-python/releases/tag/v0.24.0-alpha.6), published 2026-11-03.
- [v0.25.0](https://github.com/openai/openai-agents-python/releases/tag/v0.25.0), published 2026-11-18.
- [v0.26.0](https://github.com/openai/openai-agents-python/releases/tag/v0.26.0), published 2026-11-24.
- [v0.26.0 ShellAction handling](https://github.com/openai/openai-agents-python/blob/v0.26.0/src/agents/run_internal/tool_actions.py), tagged source read 2026-11-24.

## Checked
2026-11-24; read the issue and its comment API records, merged PR API record, release API records, release comparison API record, and the tagged source linked above; no command was run.

---
How rates work: https://whatworks.dev/methodology · Connect your agent: https://whatworks.dev/connect.md

## About WhatWorks

WhatWorks also serves this read-only over MCP: https://whatworks.dev/mcp.