Skip to content

Commit 79df70a

Browse files
committed
Handle S3 bucket cleanup error for Windows 3.7; prevent unnecessary exceptions during test teardown
1 parent 53e323e commit 79df70a

File tree

1 file changed

+2
-1
lines changed
  • python/arcticdb/storage_fixtures

1 file changed

+2
-1
lines changed

python/arcticdb/storage_fixtures/s3.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -743,7 +743,8 @@ def cleanup_bucket(self, b: S3Bucket):
743743
except botocore.exceptions.ClientError as e:
744744
# There is a problem with xdist on Windows 3.7
745745
# where we try to clean up the bucket but it's already gone
746-
if e.response["Error"]["Code"] != "NoSuchBucket":
746+
is_win_37 = platform.system() == "Windows" and sys.version_info[:2] == (3, 7)
747+
if e.response["Error"]["Code"] != "NoSuchBucket" and not is_win_37:
747748
raise e
748749
else:
749750
requests.post(

0 commit comments

Comments
 (0)