@@ -486,16 +486,21 @@ async def redirect_from_error(
486
486
487
487
if new_region is None :
488
488
logger .debug (
489
- f"S3 client configured for region { client_region } but the "
490
- f"bucket { bucket } is not in that region and the proper region "
491
- "could not be automatically determined."
489
+ "S3 client configured for region %s but the "
490
+ "bucket %s is not in that region and the proper region "
491
+ "could not be automatically determined." ,
492
+ client_region ,
493
+ bucket ,
492
494
)
493
495
return
494
496
495
497
logger .debug (
496
- f"S3 client configured for region { client_region } but the bucket { bucket } "
497
- f"is in region { new_region } ; Please configure the proper region to "
498
- f"avoid multiple unnecessary redirects and signing attempts."
498
+ "S3 client configured for region %s but the bucket %s "
499
+ "is in region %s; Please configure the proper region to "
500
+ "avoid multiple unnecessary redirects and signing attempts." ,
501
+ client_region ,
502
+ bucket ,
503
+ new_region ,
499
504
)
500
505
# Adding the new region to _cache will make construct_endpoint() to
501
506
# use the new region as value for the AWS::Region builtin parameter.
@@ -622,16 +627,21 @@ async def redirect_from_error(
622
627
623
628
if new_region is None :
624
629
logger .debug (
625
- f "S3 client configured for region { client_region } but the bucket { bucket } is not "
630
+ "S3 client configured for region %s but the bucket %s is not "
626
631
"in that region and the proper region could not be "
627
- "automatically determined."
632
+ "automatically determined." ,
633
+ client_region ,
634
+ bucket ,
628
635
)
629
636
return
630
637
631
638
logger .debug (
632
- f"S3 client configured for region { client_region } but the bucket { bucket } is in region"
633
- f" { new_region } ; Please configure the proper region to avoid multiple "
634
- "unnecessary redirects and signing attempts."
639
+ "S3 client configured for region %s but the bucket %s is in region"
640
+ " %s; Please configure the proper region to avoid multiple "
641
+ "unnecessary redirects and signing attempts." ,
642
+ client_region ,
643
+ bucket ,
644
+ new_region ,
635
645
)
636
646
endpoint = self ._endpoint_resolver .resolve ('s3' , new_region )
637
647
endpoint = endpoint ['endpoint_url' ]
0 commit comments