Skip to content

fix: redact invalid tool argument errors - #4182

Merged
seratch merged 1 commit into
mainfrom
fix/tool-argument-error-redaction
Aug 5, 2026
Merged

fix: redact invalid tool argument errors#4182
seratch merged 1 commit into
mainfrom
fix/tool-argument-error-redaction

Conversation

@seratch

@seratch seratch commented Aug 5, 2026

Copy link
Copy Markdown
Member

This pull request fixes invalid tool-argument failures leaking payload values through ModelBehaviorError messages and exception chains when DONT_LOG_TOOL_DATA=True. It applies a fixed payload-free error across direct function tools, Agent.as_tool(parameters=...), and the experimental Codex tool while preserving detailed diagnostics when tool-data logging is enabled.

It supersedes PR #4012, which identified the leak and affected validation paths. This maintainer-owned replacement applies the bounded fix to current main, preserves the original author's contribution through a Co-authored-by trailer, and intentionally does not promise redaction from arbitrary third-party capture of Python frame locals.

Co-authored-by: Illia Oleksiuk <ilya.oleksiuk@gmail.com>
@seratch seratch added this to the 0.19.x milestone Aug 5, 2026
@seratch
seratch enabled auto-merge (squash) August 5, 2026 00:25
@seratch
seratch merged commit 1ebcfd4 into main Aug 5, 2026
9 checks passed
@seratch
seratch deleted the fix/tool-argument-error-redaction branch August 5, 2026 00:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant