diff --git a/requirements_s3.txt b/requirements_s3.txt index 10c98f121..3e0038716 100644 --- a/requirements_s3.txt +++ b/requirements_s3.txt @@ -2,7 +2,7 @@ boto3==1.28.26 botocore==1.31.26 jmespath==1.0.1 python-dateutil==2.8.2 -s3path==0.4.2 +s3path==0.5.0 s3transfer==0.6.2 six==1.16.0 smart-open==6.3.0 diff --git a/src/bandersnatch_storage_plugins/s3.py b/src/bandersnatch_storage_plugins/s3.py index 93464d79b..bf65f8600 100644 --- a/src/bandersnatch_storage_plugins/s3.py +++ b/src/bandersnatch_storage_plugins/s3.py @@ -15,9 +15,9 @@ import boto3 import filelock from botocore.client import Config -from s3path import PureS3Path, S3DirEntry +from s3path import PureS3Path from s3path import S3Path as _S3Path -from s3path import register_configuration_parameter +from s3path import _S3DirEntry, register_configuration_parameter from bandersnatch.storage import PATH_TYPES, StoragePlugin @@ -332,7 +332,7 @@ def mkdir( path = self.PATH_BACKEND(path) path.joinpath(self.PATH_BACKEND.keep_file).touch() - def scandir(self, path: PATH_TYPES) -> Generator[S3DirEntry, None, None]: + def scandir(self, path: PATH_TYPES) -> Generator[_S3DirEntry, None, None]: """Read entries from the provided directory""" if not isinstance(path, self.PATH_BACKEND): path = self.PATH_BACKEND(path)