Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions src/anthropic/lib/bedrock/_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,9 @@ def get_auth_headers(
# The connection header may be stripped by a proxy somewhere, so the receiver
# of this message may not see this header, so we remove it from the set of headers
# that are signed.
headers = headers.copy()
del headers["connection"]
new_headers = {k: v for k, v in dict(headers).items() if k.lower() != "connection"}

request = AWSRequest(method=method.upper(), url=url, headers=headers, data=data)
request = AWSRequest(method=method.upper(), url=url, headers=new_headers, data=data)
credentials = session.get_credentials()
if not credentials:
raise RuntimeError("could not resolve credentials from session")
Expand Down