fix: remove deleted Anthropic beta header for AWS#4955
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughWhen ChangesAnthropic-Beta Header Cleanup
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
anthropic-betaheader when runtime header overrides are enabled but no replacementanthropic-betais provided.Why
Runtime header overrides can intentionally remove request headers. The AWS relay copied the incoming
anthropic-betaheader into the Bedrock payload even when the override map omitted it, so removed beta flags could still be forwarded upstream.Tests
go test ./relay/channel/aws -run 'TestDoAwsClientRequest_(AppliesRuntimeHeaderOverrideToAnthropicBeta|RemovesAnthropicBetaWhenRuntimeOverrideDeletesIt)'Summary by CodeRabbit
Bug Fixes
anthropic-betaheader from outgoing requests when runtime header overrides are configured without explicitly including it.Tests