Skip to content

Commit

Permalink
Map empty region to us-east-1
Browse files Browse the repository at this point in the history
In addition to ""
  • Loading branch information
mr-c committed Jul 16, 2021
1 parent 5620ff1 commit b4e3f38
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/toil/jobStores/aws/jobStore.py
Original file line number Diff line number Diff line change
Expand Up @@ -767,7 +767,7 @@ def bucket_creation_pending(error):
# produce an S3ResponseError with code
# NoSuchBucket. We let that kick us back up to the
# main retry loop.
assert self.getBucketRegion(bucket_name) == self.region, f'{self.getBucketRegion(bucket_name)} != {self.region}'
assert self.getBucketRegion(bucket_name) == self.region, f'bucket_name: {bucket_name}, {self.getBucketRegion(bucket_name)} != {self.region}'

owner_tag = os.environ.get('TOIL_OWNER_TAG')
if owner_tag:
Expand Down
2 changes: 1 addition & 1 deletion src/toil/jobStores/aws/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,4 +441,4 @@ def region_to_bucket_location(region):


def bucket_location_to_region(location):
return 'us-east-1' if location == '' else location
return 'us-east-1' if location == '' or location is None else location

0 comments on commit b4e3f38

Please sign in to comment.