You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Python: duplicate User-Agent headers when caller passes lowercase user-agent #8520
callers that pass a lowercase user-agent in default_headers (reachable through OpenAI client options) end up sending two User-Agent lines, because the prepend logic checks "User-Agent" in headers with exact casing and then adds its own.
Reproduction
prepend_agent_framework_to_user_agent({"user-agent": "my-app/1.0"})
# -> both "User-Agent: agent-framework/..." and the original lowercase one survive# httpx sends duplicate header lines
Expected behavior
header detection is case-insensitive (HTTP headers are case-insensitive); the framework value prepends to the caller's UA instead of duplicating it.
Activity