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
Stop reimplementing region resolution; let the boto3 session do it
Region was resolved by a hand-rolled os.getenv("AWS_REGION",
"AWS_DEFAULT_REGION") ladder in ~two places. That reimplements botocore's
own chain incompletely (it skips the active profile's ~/.aws/config), and
schema.py turned "no region configured" into a ValueError instead of the
loud NoRegionError boto3 raises.
Let the session resolve region: build the client with
region_name=config.region (an explicit override, or None to fall through
the chain) and read the concrete value back off client.meta.region_name
for the AMI lookup, SSM client, and ProvisionedInstance/SandboxInstanceInfo.
region stays instance data.
- schema.from_settings: drop the AWS_REGION ladder + the required-region
ValueError; region is now an optional override (None -> session resolves).
- DefaultEc2InstanceProvider: region no longer a required config field;
resolve it off the ec2 client in create_instance and find_sandbox_instances.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
0 commit comments