What
AWS_REGION and AWS_DEFAULT_REGION are checked against a region-shaped pattern before use. A value that fails the check is ignored and the fallback us-east-1 is used, where previously any non-empty value was passed through verbatim.
Details
- The Bedrock status line says so: "(default — region env var invalid, ignored; fix or unset AWS_REGION / AWS_DEFAULT_REGION)".
- The region resolver reports its source as
env-invalidin that case.
Evidence
DGg = /^[a-z]{2,}(?:-[a-z0-9]+){0,4}$/i;
Strings lifted out of the shipped bundle, so the claim above can be checked against them.
Names in the bundleAWS_REGIONAWS_DEFAULT_REGION
The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.
Confirmed since
Anthropic's documentation has since written up AWS_REGION, on Claude Code on Amazon Bedrock.
* You only need to set `AWS_REGION` to override your AWS profile's region or when your profile has no region. Claude Code resolves the region in this order:amazon-bedrock see the edit
One source agreesOne thing we can check says the same as this entry.
Anthropic's documentation agrees
Anthropic's documentation has since written up AWS_REGION, on Claude Code on Amazon Bedrock.