silo-python-sdk 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
silo/__init__.py ADDED
@@ -0,0 +1,8 @@
1
+ """Unofficial Silo Python SDK, powered by minio 7.2.20."""
2
+ from minio import Minio
3
+ from minio.error import S3Error
4
+
5
+ from .client import Silo
6
+
7
+ __version__ = "0.1.0"
8
+ __all__ = ["Silo", "Minio", "S3Error", "__version__"]
silo/api.py ADDED
@@ -0,0 +1,104 @@
1
+ """Compatibility exports from minio.api (minio 7.2.20)."""
2
+ from minio.api import (
3
+ Any as Any,
4
+ BaseHTTPResponse as BaseHTTPResponse,
5
+ BaseURL as BaseURL,
6
+ BinaryIO as BinaryIO,
7
+ Bucket as Bucket,
8
+ BytesIO as BytesIO,
9
+ COPY as COPY,
10
+ CompleteMultipartUploadResult as CompleteMultipartUploadResult,
11
+ ComposeSource as ComposeSource,
12
+ CopySource as CopySource,
13
+ Credentials as Credentials,
14
+ DeleteError as DeleteError,
15
+ DeleteObject as DeleteObject,
16
+ DeleteRequest as DeleteRequest,
17
+ DeleteResult as DeleteResult,
18
+ DictType as DictType,
19
+ ET as ET,
20
+ Element as Element,
21
+ EventIterable as EventIterable,
22
+ HTTPHeaderDict as HTTPHeaderDict,
23
+ InvalidResponseError as InvalidResponseError,
24
+ Iterable as Iterable,
25
+ Iterator as Iterator,
26
+ LegalHold as LegalHold,
27
+ LifecycleConfig as LifecycleConfig,
28
+ ListAllMyBucketsResult as ListAllMyBucketsResult,
29
+ ListMultipartUploadsResult as ListMultipartUploadsResult,
30
+ ListPartsResult as ListPartsResult,
31
+ MAX_MULTIPART_COUNT as MAX_MULTIPART_COUNT,
32
+ MAX_MULTIPART_OBJECT_SIZE as MAX_MULTIPART_OBJECT_SIZE,
33
+ MAX_PART_SIZE as MAX_PART_SIZE,
34
+ MIN_PART_SIZE as MIN_PART_SIZE,
35
+ Minio as Minio,
36
+ NotificationConfig as NotificationConfig,
37
+ Object as Object,
38
+ ObjectLockConfig as ObjectLockConfig,
39
+ ObjectWriteResult as ObjectWriteResult,
40
+ Optional as Optional,
41
+ Part as Part,
42
+ PostPolicy as PostPolicy,
43
+ ProgressType as ProgressType,
44
+ Provider as Provider,
45
+ REPLACE as REPLACE,
46
+ ReplicationConfig as ReplicationConfig,
47
+ Retention as Retention,
48
+ Retry as Retry,
49
+ S3Error as S3Error,
50
+ SSEConfig as SSEConfig,
51
+ SelectObjectReader as SelectObjectReader,
52
+ SelectRequest as SelectRequest,
53
+ ServerError as ServerError,
54
+ SnowballObject as SnowballObject,
55
+ Sse as Sse,
56
+ SseCustomerKey as SseCustomerKey,
57
+ StaticProvider as StaticProvider,
58
+ SubElement as SubElement,
59
+ Tagging as Tagging,
60
+ Tags as Tags,
61
+ TextIO as TextIO,
62
+ ThreadPool as ThreadPool,
63
+ Timeout as Timeout,
64
+ Tuple as Tuple,
65
+ Union as Union,
66
+ VersioningConfig as VersioningConfig,
67
+ absolute_import as absolute_import,
68
+ annotations as annotations,
69
+ cast as cast,
70
+ certifi as certifi,
71
+ check_bucket_name as check_bucket_name,
72
+ check_object_name as check_object_name,
73
+ check_sse as check_sse,
74
+ check_ssec as check_ssec,
75
+ datetime as datetime,
76
+ findtext as findtext,
77
+ genheaders as genheaders,
78
+ get_part_info as get_part_info,
79
+ getbytes as getbytes,
80
+ headers_to_strings as headers_to_strings,
81
+ is_valid_policy_type as is_valid_policy_type,
82
+ itertools as itertools,
83
+ json as json,
84
+ makedirs as makedirs,
85
+ marshal as marshal,
86
+ md5sum_hash as md5sum_hash,
87
+ os as os,
88
+ parse_copy_object as parse_copy_object,
89
+ parse_list_objects as parse_list_objects,
90
+ presign_v4 as presign_v4,
91
+ queryencode as queryencode,
92
+ random as random,
93
+ read_part_data as read_part_data,
94
+ sha256_hash as sha256_hash,
95
+ sign_v4_s3 as sign_v4_s3,
96
+ tarfile as tarfile,
97
+ time as time,
98
+ timedelta as timedelta,
99
+ unmarshal as unmarshal,
100
+ urllib3 as urllib3,
101
+ urlunsplit as urlunsplit,
102
+ )
103
+
104
+ __all__ = ['Any', 'BaseHTTPResponse', 'BaseURL', 'BinaryIO', 'Bucket', 'BytesIO', 'COPY', 'CompleteMultipartUploadResult', 'ComposeSource', 'CopySource', 'Credentials', 'DeleteError', 'DeleteObject', 'DeleteRequest', 'DeleteResult', 'DictType', 'ET', 'Element', 'EventIterable', 'HTTPHeaderDict', 'InvalidResponseError', 'Iterable', 'Iterator', 'LegalHold', 'LifecycleConfig', 'ListAllMyBucketsResult', 'ListMultipartUploadsResult', 'ListPartsResult', 'MAX_MULTIPART_COUNT', 'MAX_MULTIPART_OBJECT_SIZE', 'MAX_PART_SIZE', 'MIN_PART_SIZE', 'Minio', 'NotificationConfig', 'Object', 'ObjectLockConfig', 'ObjectWriteResult', 'Optional', 'Part', 'PostPolicy', 'ProgressType', 'Provider', 'REPLACE', 'ReplicationConfig', 'Retention', 'Retry', 'S3Error', 'SSEConfig', 'SelectObjectReader', 'SelectRequest', 'ServerError', 'SnowballObject', 'Sse', 'SseCustomerKey', 'StaticProvider', 'SubElement', 'Tagging', 'Tags', 'TextIO', 'ThreadPool', 'Timeout', 'Tuple', 'Union', 'VersioningConfig', 'absolute_import', 'annotations', 'cast', 'certifi', 'check_bucket_name', 'check_object_name', 'check_sse', 'check_ssec', 'datetime', 'findtext', 'genheaders', 'get_part_info', 'getbytes', 'headers_to_strings', 'is_valid_policy_type', 'itertools', 'json', 'makedirs', 'marshal', 'md5sum_hash', 'os', 'parse_copy_object', 'parse_list_objects', 'presign_v4', 'queryencode', 'random', 'read_part_data', 'sha256_hash', 'sign_v4_s3', 'tarfile', 'time', 'timedelta', 'unmarshal', 'urllib3', 'urlunsplit']
silo/client.py ADDED
@@ -0,0 +1,65 @@
1
+ """Silo convenience methods; all upstream MinIO methods remain inherited."""
2
+ import os
3
+ from io import BytesIO
4
+
5
+ from minio import Minio
6
+ from minio.helpers import ObjectWriteResult
7
+
8
+
9
+ class Silo(Minio):
10
+ """Silo S3 client with the unchanged Minio constructor and public API."""
11
+
12
+ @classmethod
13
+ def from_env(cls) -> "Silo":
14
+ """Read SILO_* credentials; HTTPS defaults on, booleans are true/false.
15
+
16
+ SILO_ENDPOINT uses the upstream host:port format, without a URL scheme.
17
+ Missing credentials or an invalid SILO_SECURE value raise ValueError.
18
+ """
19
+ values = {}
20
+ for key in ("SILO_ENDPOINT", "SILO_ACCESS_KEY", "SILO_SECRET_KEY"):
21
+ value = os.environ.get(key)
22
+ if value is None or not value.strip():
23
+ raise ValueError(f"{key} is required")
24
+ values[key] = value
25
+ secure = os.environ.get("SILO_SECURE", "true").strip().lower()
26
+ if secure not in ("true", "false"):
27
+ raise ValueError("SILO_SECURE must be 'true' or 'false'")
28
+ return cls(
29
+ values["SILO_ENDPOINT"].strip(),
30
+ access_key=values["SILO_ACCESS_KEY"],
31
+ secret_key=values["SILO_SECRET_KEY"],
32
+ secure=secure == "true",
33
+ )
34
+
35
+ def upload_bytes(
36
+ self,
37
+ bucket_name: str,
38
+ object_name: str,
39
+ data: bytes,
40
+ content_type: str = "application/octet-stream",
41
+ ) -> ObjectWriteResult:
42
+ """Upload in-memory bytes and return the upstream ObjectWriteResult.
43
+
44
+ For streams, metadata, encryption or large files, use inherited
45
+ put_object/fput_object with their complete upstream options.
46
+ """
47
+ return self.put_object(
48
+ bucket_name, object_name, BytesIO(data), len(data),
49
+ content_type=content_type,
50
+ )
51
+
52
+ def download_bytes(self, bucket_name: str, object_name: str) -> bytes:
53
+ """Read an object fully into memory, always releasing the connection.
54
+
55
+ For large objects, ranges or version IDs, use inherited get_object
56
+ or fget_object. S3/network errors propagate unchanged.
57
+ """
58
+ response = self.get_object(bucket_name, object_name)
59
+ try:
60
+ return response.read()
61
+ finally:
62
+ try:
63
+ response.close()
64
+ finally:
65
+ response.release_conn()
silo/commonconfig.py ADDED
@@ -0,0 +1,48 @@
1
+ """Compatibility exports from minio.commonconfig (minio 7.2.20)."""
2
+ from minio.commonconfig import (
3
+ A as A,
4
+ ABC as ABC,
5
+ AndOperator as AndOperator,
6
+ B as B,
7
+ BaseRule as BaseRule,
8
+ C as C,
9
+ COMPLIANCE as COMPLIANCE,
10
+ COPY as COPY,
11
+ ComposeSource as ComposeSource,
12
+ CopySource as CopySource,
13
+ D as D,
14
+ DISABLED as DISABLED,
15
+ E as E,
16
+ ENABLED as ENABLED,
17
+ ET as ET,
18
+ F as F,
19
+ Filter as Filter,
20
+ GOVERNANCE as GOVERNANCE,
21
+ IO as IO,
22
+ MinioException as MinioException,
23
+ ObjectConditionalReadArgs as ObjectConditionalReadArgs,
24
+ Optional as Optional,
25
+ REPLACE as REPLACE,
26
+ SnowballObject as SnowballObject,
27
+ SseCustomerKey as SseCustomerKey,
28
+ SubElement as SubElement,
29
+ Tag as Tag,
30
+ Tags as Tags,
31
+ Type as Type,
32
+ TypeVar as TypeVar,
33
+ absolute_import as absolute_import,
34
+ abstractmethod as abstractmethod,
35
+ annotations as annotations,
36
+ cast as cast,
37
+ check_status as check_status,
38
+ dataclass as dataclass,
39
+ datetime as datetime,
40
+ field as field,
41
+ find as find,
42
+ findall as findall,
43
+ findtext as findtext,
44
+ quote as quote,
45
+ to_http_header as to_http_header,
46
+ )
47
+
48
+ __all__ = ['A', 'ABC', 'AndOperator', 'B', 'BaseRule', 'C', 'COMPLIANCE', 'COPY', 'ComposeSource', 'CopySource', 'D', 'DISABLED', 'E', 'ENABLED', 'ET', 'F', 'Filter', 'GOVERNANCE', 'IO', 'MinioException', 'ObjectConditionalReadArgs', 'Optional', 'REPLACE', 'SnowballObject', 'SseCustomerKey', 'SubElement', 'Tag', 'Tags', 'Type', 'TypeVar', 'absolute_import', 'abstractmethod', 'annotations', 'cast', 'check_status', 'dataclass', 'datetime', 'field', 'find', 'findall', 'findtext', 'quote', 'to_http_header']
@@ -0,0 +1,26 @@
1
+ """Compatibility exports from minio.credentials (minio 7.2.20)."""
2
+ from minio.credentials import (
3
+ AWSConfigProvider as AWSConfigProvider,
4
+ AssumeRoleProvider as AssumeRoleProvider,
5
+ CertificateIdentityProvider as CertificateIdentityProvider,
6
+ ChainedProvider as ChainedProvider,
7
+ ClientGrantsProvider as ClientGrantsProvider,
8
+ Credentials as Credentials,
9
+ EnvAWSProvider as EnvAWSProvider,
10
+ EnvMinioProvider as EnvMinioProvider,
11
+ IamAwsProvider as IamAwsProvider,
12
+ LdapIdentityProvider as LdapIdentityProvider,
13
+ MinioClientConfigProvider as MinioClientConfigProvider,
14
+ Provider as Provider,
15
+ StaticProvider as StaticProvider,
16
+ WebIdentityProvider as WebIdentityProvider,
17
+ credentials as credentials,
18
+ providers as providers,
19
+ )
20
+
21
+ __all__ = ['AWSConfigProvider', 'AssumeRoleProvider', 'CertificateIdentityProvider', 'ChainedProvider', 'ClientGrantsProvider', 'Credentials', 'EnvAWSProvider', 'EnvMinioProvider', 'IamAwsProvider', 'LdapIdentityProvider', 'MinioClientConfigProvider', 'Provider', 'StaticProvider', 'WebIdentityProvider', 'credentials', 'providers']
22
+
23
+ # Preserve upstream module identity even when consumers import child modules.
24
+ import sys as _sys
25
+ _sys.modules[__name__ + '.credentials'] = credentials
26
+ _sys.modules[__name__ + '.providers'] = providers
@@ -0,0 +1,12 @@
1
+ """Compatibility exports from minio.credentials.credentials (minio 7.2.20)."""
2
+ from minio.credentials.credentials import (
3
+ Credentials as Credentials,
4
+ Optional as Optional,
5
+ annotations as annotations,
6
+ dataclass as dataclass,
7
+ datetime as datetime,
8
+ timedelta as timedelta,
9
+ timezone as timezone,
10
+ )
11
+
12
+ __all__ = ['Credentials', 'Optional', 'annotations', 'dataclass', 'datetime', 'timedelta', 'timezone']
@@ -0,0 +1,53 @@
1
+ """Compatibility exports from minio.credentials.providers (minio 7.2.20)."""
2
+ from minio.credentials.providers import (
3
+ ABC as ABC,
4
+ AWSConfigProvider as AWSConfigProvider,
5
+ AssumeRoleProvider as AssumeRoleProvider,
6
+ BaseHTTPResponse as BaseHTTPResponse,
7
+ Callable as Callable,
8
+ CertificateIdentityProvider as CertificateIdentityProvider,
9
+ ChainedProvider as ChainedProvider,
10
+ ClientGrantsProvider as ClientGrantsProvider,
11
+ Credentials as Credentials,
12
+ ET as ET,
13
+ EnvAWSProvider as EnvAWSProvider,
14
+ EnvMinioProvider as EnvMinioProvider,
15
+ IamAwsProvider as IamAwsProvider,
16
+ LdapIdentityProvider as LdapIdentityProvider,
17
+ MinioClientConfigProvider as MinioClientConfigProvider,
18
+ Optional as Optional,
19
+ Path as Path,
20
+ PoolManager as PoolManager,
21
+ Provider as Provider,
22
+ Retry as Retry,
23
+ StaticProvider as StaticProvider,
24
+ WebIdentityClientGrantsProvider as WebIdentityClientGrantsProvider,
25
+ WebIdentityProvider as WebIdentityProvider,
26
+ abstractmethod as abstractmethod,
27
+ annotations as annotations,
28
+ cast as cast,
29
+ certifi as certifi,
30
+ configparser as configparser,
31
+ find as find,
32
+ findtext as findtext,
33
+ from_iso8601utc as from_iso8601utc,
34
+ ipaddress as ipaddress,
35
+ json as json,
36
+ os as os,
37
+ parse_url as parse_url,
38
+ re as re,
39
+ sha256_hash as sha256_hash,
40
+ sign_v4_sts as sign_v4_sts,
41
+ socket as socket,
42
+ sys as sys,
43
+ time as time,
44
+ timedelta as timedelta,
45
+ to_amz_date as to_amz_date,
46
+ url_replace as url_replace,
47
+ urlencode as urlencode,
48
+ urlsplit as urlsplit,
49
+ urlunsplit as urlunsplit,
50
+ utcnow as utcnow,
51
+ )
52
+
53
+ __all__ = ['ABC', 'AWSConfigProvider', 'AssumeRoleProvider', 'BaseHTTPResponse', 'Callable', 'CertificateIdentityProvider', 'ChainedProvider', 'ClientGrantsProvider', 'Credentials', 'ET', 'EnvAWSProvider', 'EnvMinioProvider', 'IamAwsProvider', 'LdapIdentityProvider', 'MinioClientConfigProvider', 'Optional', 'Path', 'PoolManager', 'Provider', 'Retry', 'StaticProvider', 'WebIdentityClientGrantsProvider', 'WebIdentityProvider', 'abstractmethod', 'annotations', 'cast', 'certifi', 'configparser', 'find', 'findtext', 'from_iso8601utc', 'ipaddress', 'json', 'os', 'parse_url', 're', 'sha256_hash', 'sign_v4_sts', 'socket', 'sys', 'time', 'timedelta', 'to_amz_date', 'url_replace', 'urlencode', 'urlsplit', 'urlunsplit', 'utcnow']
silo/crypto.py ADDED
@@ -0,0 +1,18 @@
1
+ """Compatibility exports from minio.crypto (minio 7.2.20)."""
2
+ from minio.crypto import (
3
+ AES as AES,
4
+ BaseHTTPResponse as BaseHTTPResponse,
5
+ ChaCha20Poly1305Cipher as ChaCha20Poly1305Cipher,
6
+ ChaCha20_Poly1305 as ChaCha20_Poly1305,
7
+ DecryptReader as DecryptReader,
8
+ GcmMode as GcmMode,
9
+ Type as Type,
10
+ absolute_import as absolute_import,
11
+ annotations as annotations,
12
+ decrypt as decrypt,
13
+ encrypt as encrypt,
14
+ hash_secret_raw as hash_secret_raw,
15
+ os as os,
16
+ )
17
+
18
+ __all__ = ['AES', 'BaseHTTPResponse', 'ChaCha20Poly1305Cipher', 'ChaCha20_Poly1305', 'DecryptReader', 'GcmMode', 'Type', 'absolute_import', 'annotations', 'decrypt', 'encrypt', 'hash_secret_raw', 'os']
silo/datatypes.py ADDED
@@ -0,0 +1,56 @@
1
+ """Compatibility exports from minio.datatypes (minio 7.2.20)."""
2
+ from minio.datatypes import (
3
+ A as A,
4
+ Any as Any,
5
+ B as B,
6
+ BaseHTTPResponse as BaseHTTPResponse,
7
+ Bucket as Bucket,
8
+ C as C,
9
+ CompleteMultipartUploadResult as CompleteMultipartUploadResult,
10
+ Credentials as Credentials,
11
+ ET as ET,
12
+ Enum as Enum,
13
+ EventIterable as EventIterable,
14
+ HTTPHeaderDict as HTTPHeaderDict,
15
+ JSONDecodeError as JSONDecodeError,
16
+ List as List,
17
+ ListAllMyBucketsResult as ListAllMyBucketsResult,
18
+ ListMultipartUploadsResult as ListMultipartUploadsResult,
19
+ ListPartsResult as ListPartsResult,
20
+ Object as Object,
21
+ Optional as Optional,
22
+ OrderedDict as OrderedDict,
23
+ Part as Part,
24
+ PeerInfo as PeerInfo,
25
+ PeerSite as PeerSite,
26
+ PostPolicy as PostPolicy,
27
+ SiteReplicationStatusOptions as SiteReplicationStatusOptions,
28
+ Tags as Tags,
29
+ Tuple as Tuple,
30
+ Type as Type,
31
+ TypeVar as TypeVar,
32
+ Union as Union,
33
+ Upload as Upload,
34
+ absolute_import as absolute_import,
35
+ annotations as annotations,
36
+ base64 as base64,
37
+ cast as cast,
38
+ check_bucket_name as check_bucket_name,
39
+ dataclass as dataclass,
40
+ datetime as datetime,
41
+ field as field,
42
+ find as find,
43
+ findall as findall,
44
+ findtext as findtext,
45
+ from_iso8601utc as from_iso8601utc,
46
+ get_credential_string as get_credential_string,
47
+ json as json,
48
+ parse_copy_object as parse_copy_object,
49
+ parse_list_objects as parse_list_objects,
50
+ post_presign_v4 as post_presign_v4,
51
+ to_amz_date as to_amz_date,
52
+ to_iso8601utc as to_iso8601utc,
53
+ unquote_plus as unquote_plus,
54
+ )
55
+
56
+ __all__ = ['A', 'Any', 'B', 'BaseHTTPResponse', 'Bucket', 'C', 'CompleteMultipartUploadResult', 'Credentials', 'ET', 'Enum', 'EventIterable', 'HTTPHeaderDict', 'JSONDecodeError', 'List', 'ListAllMyBucketsResult', 'ListMultipartUploadsResult', 'ListPartsResult', 'Object', 'Optional', 'OrderedDict', 'Part', 'PeerInfo', 'PeerSite', 'PostPolicy', 'SiteReplicationStatusOptions', 'Tags', 'Tuple', 'Type', 'TypeVar', 'Union', 'Upload', 'absolute_import', 'annotations', 'base64', 'cast', 'check_bucket_name', 'dataclass', 'datetime', 'field', 'find', 'findall', 'findtext', 'from_iso8601utc', 'get_credential_string', 'json', 'parse_copy_object', 'parse_list_objects', 'post_presign_v4', 'to_amz_date', 'to_iso8601utc', 'unquote_plus']
silo/deleteobjects.py ADDED
@@ -0,0 +1,25 @@
1
+ """Compatibility exports from minio.deleteobjects (minio 7.2.20)."""
2
+ from minio.deleteobjects import (
3
+ A as A,
4
+ B as B,
5
+ C as C,
6
+ DeleteError as DeleteError,
7
+ DeleteObject as DeleteObject,
8
+ DeleteRequest as DeleteRequest,
9
+ DeleteResult as DeleteResult,
10
+ DeletedObject as DeletedObject,
11
+ ET as ET,
12
+ Element as Element,
13
+ Optional as Optional,
14
+ SubElement as SubElement,
15
+ Type as Type,
16
+ TypeVar as TypeVar,
17
+ absolute_import as absolute_import,
18
+ annotations as annotations,
19
+ cast as cast,
20
+ dataclass as dataclass,
21
+ findall as findall,
22
+ findtext as findtext,
23
+ )
24
+
25
+ __all__ = ['A', 'B', 'C', 'DeleteError', 'DeleteObject', 'DeleteRequest', 'DeleteResult', 'DeletedObject', 'ET', 'Element', 'Optional', 'SubElement', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'findall', 'findtext']
silo/error.py ADDED
@@ -0,0 +1,19 @@
1
+ """Compatibility exports from minio.error (minio 7.2.20)."""
2
+ from minio.error import (
3
+ A as A,
4
+ BaseHTTPResponse as BaseHTTPResponse,
5
+ ET as ET,
6
+ InvalidResponseError as InvalidResponseError,
7
+ MinioAdminException as MinioAdminException,
8
+ MinioException as MinioException,
9
+ Optional as Optional,
10
+ S3Error as S3Error,
11
+ ServerError as ServerError,
12
+ Type as Type,
13
+ TypeVar as TypeVar,
14
+ absolute_import as absolute_import,
15
+ annotations as annotations,
16
+ findtext as findtext,
17
+ )
18
+
19
+ __all__ = ['A', 'BaseHTTPResponse', 'ET', 'InvalidResponseError', 'MinioAdminException', 'MinioException', 'Optional', 'S3Error', 'ServerError', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'findtext']
silo/helpers.py ADDED
@@ -0,0 +1,61 @@
1
+ """Compatibility exports from minio.helpers (minio 7.2.20)."""
2
+ from minio.helpers import (
3
+ BaseURL as BaseURL,
4
+ BinaryIO as BinaryIO,
5
+ BoundedSemaphore as BoundedSemaphore,
6
+ Dict as Dict,
7
+ DictType as DictType,
8
+ HTTPHeaderDict as HTTPHeaderDict,
9
+ List as List,
10
+ MAX_MULTIPART_COUNT as MAX_MULTIPART_COUNT,
11
+ MAX_MULTIPART_OBJECT_SIZE as MAX_MULTIPART_OBJECT_SIZE,
12
+ MAX_PART_SIZE as MAX_PART_SIZE,
13
+ MIN_PART_SIZE as MIN_PART_SIZE,
14
+ Mapping as Mapping,
15
+ ObjectWriteResult as ObjectWriteResult,
16
+ Optional as Optional,
17
+ ProgressType as ProgressType,
18
+ Protocol as Protocol,
19
+ Queue as Queue,
20
+ Sse as Sse,
21
+ SseCustomerKey as SseCustomerKey,
22
+ Thread as Thread,
23
+ ThreadPool as ThreadPool,
24
+ Tuple as Tuple,
25
+ Union as Union,
26
+ Worker as Worker,
27
+ absolute_import as absolute_import,
28
+ annotations as annotations,
29
+ base64 as base64,
30
+ check_bucket_name as check_bucket_name,
31
+ check_non_empty_string as check_non_empty_string,
32
+ check_object_name as check_object_name,
33
+ check_sse as check_sse,
34
+ check_ssec as check_ssec,
35
+ dataclass as dataclass,
36
+ datetime as datetime,
37
+ division as division,
38
+ errno as errno,
39
+ genheaders as genheaders,
40
+ get_part_info as get_part_info,
41
+ hashlib as hashlib,
42
+ headers_to_strings as headers_to_strings,
43
+ is_valid_policy_type as is_valid_policy_type,
44
+ makedirs as makedirs,
45
+ math as math,
46
+ md5sum_hash as md5sum_hash,
47
+ normalize_headers as normalize_headers,
48
+ os as os,
49
+ platform as platform,
50
+ queryencode as queryencode,
51
+ quote as quote,
52
+ re as re,
53
+ read_part_data as read_part_data,
54
+ sha256_hash as sha256_hash,
55
+ to_iso8601utc as to_iso8601utc,
56
+ unicode_literals as unicode_literals,
57
+ url_replace as url_replace,
58
+ urllib as urllib,
59
+ )
60
+
61
+ __all__ = ['BaseURL', 'BinaryIO', 'BoundedSemaphore', 'Dict', 'DictType', 'HTTPHeaderDict', 'List', 'MAX_MULTIPART_COUNT', 'MAX_MULTIPART_OBJECT_SIZE', 'MAX_PART_SIZE', 'MIN_PART_SIZE', 'Mapping', 'ObjectWriteResult', 'Optional', 'ProgressType', 'Protocol', 'Queue', 'Sse', 'SseCustomerKey', 'Thread', 'ThreadPool', 'Tuple', 'Union', 'Worker', 'absolute_import', 'annotations', 'base64', 'check_bucket_name', 'check_non_empty_string', 'check_object_name', 'check_sse', 'check_ssec', 'dataclass', 'datetime', 'division', 'errno', 'genheaders', 'get_part_info', 'hashlib', 'headers_to_strings', 'is_valid_policy_type', 'makedirs', 'math', 'md5sum_hash', 'normalize_headers', 'os', 'platform', 'queryencode', 'quote', 're', 'read_part_data', 'sha256_hash', 'to_iso8601utc', 'unicode_literals', 'url_replace', 'urllib']
silo/legalhold.py ADDED
@@ -0,0 +1,17 @@
1
+ """Compatibility exports from minio.legalhold (minio 7.2.20)."""
2
+ from minio.legalhold import (
3
+ A as A,
4
+ ET as ET,
5
+ Element as Element,
6
+ LegalHold as LegalHold,
7
+ Optional as Optional,
8
+ SubElement as SubElement,
9
+ Type as Type,
10
+ TypeVar as TypeVar,
11
+ absolute_import as absolute_import,
12
+ annotations as annotations,
13
+ dataclass as dataclass,
14
+ findtext as findtext,
15
+ )
16
+
17
+ __all__ = ['A', 'ET', 'Element', 'LegalHold', 'Optional', 'SubElement', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'dataclass', 'findtext']
@@ -0,0 +1,38 @@
1
+ """Compatibility exports from minio.lifecycleconfig (minio 7.2.20)."""
2
+ from minio.lifecycleconfig import (
3
+ A as A,
4
+ ABC as ABC,
5
+ AbortIncompleteMultipartUpload as AbortIncompleteMultipartUpload,
6
+ B as B,
7
+ BaseRule as BaseRule,
8
+ C as C,
9
+ D as D,
10
+ DateDays as DateDays,
11
+ E as E,
12
+ ET as ET,
13
+ Element as Element,
14
+ Expiration as Expiration,
15
+ F as F,
16
+ G as G,
17
+ LifecycleConfig as LifecycleConfig,
18
+ NoncurrentVersionExpiration as NoncurrentVersionExpiration,
19
+ NoncurrentVersionTransition as NoncurrentVersionTransition,
20
+ Optional as Optional,
21
+ Rule as Rule,
22
+ SubElement as SubElement,
23
+ Transition as Transition,
24
+ Type as Type,
25
+ TypeVar as TypeVar,
26
+ absolute_import as absolute_import,
27
+ annotations as annotations,
28
+ cast as cast,
29
+ dataclass as dataclass,
30
+ datetime as datetime,
31
+ find as find,
32
+ findall as findall,
33
+ findtext as findtext,
34
+ from_iso8601utc as from_iso8601utc,
35
+ to_iso8601utc as to_iso8601utc,
36
+ )
37
+
38
+ __all__ = ['A', 'ABC', 'AbortIncompleteMultipartUpload', 'B', 'BaseRule', 'C', 'D', 'DateDays', 'E', 'ET', 'Element', 'Expiration', 'F', 'G', 'LifecycleConfig', 'NoncurrentVersionExpiration', 'NoncurrentVersionTransition', 'Optional', 'Rule', 'SubElement', 'Transition', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'datetime', 'find', 'findall', 'findtext', 'from_iso8601utc', 'to_iso8601utc']
silo/minioadmin.py ADDED
@@ -0,0 +1,39 @@
1
+ """Compatibility exports from minio.minioadmin (minio 7.2.20)."""
2
+ from minio.minioadmin import (
3
+ Any as Any,
4
+ BaseHTTPResponse as BaseHTTPResponse,
5
+ DictType as DictType,
6
+ Enum as Enum,
7
+ HTTPHeaderDict as HTTPHeaderDict,
8
+ MinioAdmin as MinioAdmin,
9
+ MinioAdminException as MinioAdminException,
10
+ Optional as Optional,
11
+ PeerInfo as PeerInfo,
12
+ PeerSite as PeerSite,
13
+ PoolManager as PoolManager,
14
+ Provider as Provider,
15
+ Retry as Retry,
16
+ SiteReplicationStatusOptions as SiteReplicationStatusOptions,
17
+ TextIO as TextIO,
18
+ Timeout as Timeout,
19
+ Tuple as Tuple,
20
+ absolute_import as absolute_import,
21
+ annotations as annotations,
22
+ cast as cast,
23
+ certifi as certifi,
24
+ decrypt as decrypt,
25
+ encrypt as encrypt,
26
+ headers_to_strings as headers_to_strings,
27
+ json as json,
28
+ os as os,
29
+ queryencode as queryencode,
30
+ sha256_hash as sha256_hash,
31
+ sign_v4_s3 as sign_v4_s3,
32
+ time as time,
33
+ timedelta as timedelta,
34
+ unique as unique,
35
+ url_replace as url_replace,
36
+ urlunsplit as urlunsplit,
37
+ )
38
+
39
+ __all__ = ['Any', 'BaseHTTPResponse', 'DictType', 'Enum', 'HTTPHeaderDict', 'MinioAdmin', 'MinioAdminException', 'Optional', 'PeerInfo', 'PeerSite', 'PoolManager', 'Provider', 'Retry', 'SiteReplicationStatusOptions', 'TextIO', 'Timeout', 'Tuple', 'absolute_import', 'annotations', 'cast', 'certifi', 'decrypt', 'encrypt', 'headers_to_strings', 'json', 'os', 'queryencode', 'sha256_hash', 'sign_v4_s3', 'time', 'timedelta', 'unique', 'url_replace', 'urlunsplit']
@@ -0,0 +1,33 @@
1
+ """Compatibility exports from minio.notificationconfig (minio 7.2.20)."""
2
+ from minio.notificationconfig import (
3
+ A as A,
4
+ ABC as ABC,
5
+ B as B,
6
+ C as C,
7
+ CloudFuncConfig as CloudFuncConfig,
8
+ CommonConfig as CommonConfig,
9
+ D as D,
10
+ E as E,
11
+ ET as ET,
12
+ Element as Element,
13
+ FilterRule as FilterRule,
14
+ NotificationConfig as NotificationConfig,
15
+ Optional as Optional,
16
+ PrefixFilterRule as PrefixFilterRule,
17
+ QueueConfig as QueueConfig,
18
+ SubElement as SubElement,
19
+ SuffixFilterRule as SuffixFilterRule,
20
+ TopicConfig as TopicConfig,
21
+ Type as Type,
22
+ TypeVar as TypeVar,
23
+ absolute_import as absolute_import,
24
+ annotations as annotations,
25
+ cast as cast,
26
+ dataclass as dataclass,
27
+ field as field,
28
+ find as find,
29
+ findall as findall,
30
+ findtext as findtext,
31
+ )
32
+
33
+ __all__ = ['A', 'ABC', 'B', 'C', 'CloudFuncConfig', 'CommonConfig', 'D', 'E', 'ET', 'Element', 'FilterRule', 'NotificationConfig', 'Optional', 'PrefixFilterRule', 'QueueConfig', 'SubElement', 'SuffixFilterRule', 'TopicConfig', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'field', 'find', 'findall', 'findtext']
@@ -0,0 +1,24 @@
1
+ """Compatibility exports from minio.objectlockconfig (minio 7.2.20)."""
2
+ from minio.objectlockconfig import (
3
+ A as A,
4
+ COMPLIANCE as COMPLIANCE,
5
+ DAYS as DAYS,
6
+ ENABLED as ENABLED,
7
+ ET as ET,
8
+ Element as Element,
9
+ GOVERNANCE as GOVERNANCE,
10
+ ObjectLockConfig as ObjectLockConfig,
11
+ Optional as Optional,
12
+ SubElement as SubElement,
13
+ Type as Type,
14
+ TypeVar as TypeVar,
15
+ YEARS as YEARS,
16
+ absolute_import as absolute_import,
17
+ annotations as annotations,
18
+ cast as cast,
19
+ dataclass as dataclass,
20
+ find as find,
21
+ findtext as findtext,
22
+ )
23
+
24
+ __all__ = ['A', 'COMPLIANCE', 'DAYS', 'ENABLED', 'ET', 'Element', 'GOVERNANCE', 'ObjectLockConfig', 'Optional', 'SubElement', 'Type', 'TypeVar', 'YEARS', 'absolute_import', 'annotations', 'cast', 'dataclass', 'find', 'findtext']
silo/py.typed ADDED
File without changes
@@ -0,0 +1,48 @@
1
+ """Compatibility exports from minio.replicationconfig (minio 7.2.20)."""
2
+ from minio.replicationconfig import (
3
+ A as A,
4
+ ABC as ABC,
5
+ AccessControlTranslation as AccessControlTranslation,
6
+ B as B,
7
+ BaseRule as BaseRule,
8
+ C as C,
9
+ D as D,
10
+ DISABLED as DISABLED,
11
+ DeleteMarkerReplication as DeleteMarkerReplication,
12
+ Destination as Destination,
13
+ E as E,
14
+ ET as ET,
15
+ Element as Element,
16
+ EncryptionConfig as EncryptionConfig,
17
+ EventThreshold as EventThreshold,
18
+ ExistingObjectReplication as ExistingObjectReplication,
19
+ F as F,
20
+ Filter as Filter,
21
+ G as G,
22
+ H as H,
23
+ I as I,
24
+ J as J,
25
+ Metrics as Metrics,
26
+ Optional as Optional,
27
+ ReplicationConfig as ReplicationConfig,
28
+ ReplicationTime as ReplicationTime,
29
+ ReplicationTimeValue as ReplicationTimeValue,
30
+ Rule as Rule,
31
+ SourceSelectionCriteria as SourceSelectionCriteria,
32
+ SseKmsEncryptedObjects as SseKmsEncryptedObjects,
33
+ Status as Status,
34
+ SubElement as SubElement,
35
+ Time as Time,
36
+ Type as Type,
37
+ TypeVar as TypeVar,
38
+ absolute_import as absolute_import,
39
+ annotations as annotations,
40
+ cast as cast,
41
+ check_status as check_status,
42
+ dataclass as dataclass,
43
+ find as find,
44
+ findall as findall,
45
+ findtext as findtext,
46
+ )
47
+
48
+ __all__ = ['A', 'ABC', 'AccessControlTranslation', 'B', 'BaseRule', 'C', 'D', 'DISABLED', 'DeleteMarkerReplication', 'Destination', 'E', 'ET', 'Element', 'EncryptionConfig', 'EventThreshold', 'ExistingObjectReplication', 'F', 'Filter', 'G', 'H', 'I', 'J', 'Metrics', 'Optional', 'ReplicationConfig', 'ReplicationTime', 'ReplicationTimeValue', 'Rule', 'SourceSelectionCriteria', 'SseKmsEncryptedObjects', 'Status', 'SubElement', 'Time', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'check_status', 'dataclass', 'find', 'findall', 'findtext']
silo/retention.py ADDED
@@ -0,0 +1,23 @@
1
+ """Compatibility exports from minio.retention (minio 7.2.20)."""
2
+ from minio.retention import (
3
+ A as A,
4
+ COMPLIANCE as COMPLIANCE,
5
+ ET as ET,
6
+ Element as Element,
7
+ GOVERNANCE as GOVERNANCE,
8
+ Optional as Optional,
9
+ Retention as Retention,
10
+ SubElement as SubElement,
11
+ Type as Type,
12
+ TypeVar as TypeVar,
13
+ absolute_import as absolute_import,
14
+ annotations as annotations,
15
+ cast as cast,
16
+ dataclass as dataclass,
17
+ datetime as datetime,
18
+ findtext as findtext,
19
+ from_iso8601utc as from_iso8601utc,
20
+ to_iso8601utc as to_iso8601utc,
21
+ )
22
+
23
+ __all__ = ['A', 'COMPLIANCE', 'ET', 'Element', 'GOVERNANCE', 'Optional', 'Retention', 'SubElement', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'datetime', 'findtext', 'from_iso8601utc', 'to_iso8601utc']
silo/select.py ADDED
@@ -0,0 +1,37 @@
1
+ """Compatibility exports from minio.select (minio 7.2.20)."""
2
+ from minio.select import (
3
+ ABC as ABC,
4
+ BytesIO as BytesIO,
5
+ COMPRESSION_TYPE_BZIP2 as COMPRESSION_TYPE_BZIP2,
6
+ COMPRESSION_TYPE_GZIP as COMPRESSION_TYPE_GZIP,
7
+ COMPRESSION_TYPE_NONE as COMPRESSION_TYPE_NONE,
8
+ CSVInputSerialization as CSVInputSerialization,
9
+ CSVOutputSerialization as CSVOutputSerialization,
10
+ ET as ET,
11
+ Element as Element,
12
+ FILE_HEADER_INFO_IGNORE as FILE_HEADER_INFO_IGNORE,
13
+ FILE_HEADER_INFO_NONE as FILE_HEADER_INFO_NONE,
14
+ FILE_HEADER_INFO_USE as FILE_HEADER_INFO_USE,
15
+ InputSerialization as InputSerialization,
16
+ JSONInputSerialization as JSONInputSerialization,
17
+ JSONOutputSerialization as JSONOutputSerialization,
18
+ JSON_TYPE_DOCUMENT as JSON_TYPE_DOCUMENT,
19
+ JSON_TYPE_LINES as JSON_TYPE_LINES,
20
+ MinioException as MinioException,
21
+ Optional as Optional,
22
+ OutputSerialization as OutputSerialization,
23
+ ParquetInputSerialization as ParquetInputSerialization,
24
+ QUOTE_FIELDS_ALWAYS as QUOTE_FIELDS_ALWAYS,
25
+ QUOTE_FIELDS_ASNEEDED as QUOTE_FIELDS_ASNEEDED,
26
+ SelectObjectReader as SelectObjectReader,
27
+ SelectRequest as SelectRequest,
28
+ Stats as Stats,
29
+ SubElement as SubElement,
30
+ absolute_import as absolute_import,
31
+ abstractmethod as abstractmethod,
32
+ crc32 as crc32,
33
+ dataclass as dataclass,
34
+ findtext as findtext,
35
+ )
36
+
37
+ __all__ = ['ABC', 'BytesIO', 'COMPRESSION_TYPE_BZIP2', 'COMPRESSION_TYPE_GZIP', 'COMPRESSION_TYPE_NONE', 'CSVInputSerialization', 'CSVOutputSerialization', 'ET', 'Element', 'FILE_HEADER_INFO_IGNORE', 'FILE_HEADER_INFO_NONE', 'FILE_HEADER_INFO_USE', 'InputSerialization', 'JSONInputSerialization', 'JSONOutputSerialization', 'JSON_TYPE_DOCUMENT', 'JSON_TYPE_LINES', 'MinioException', 'Optional', 'OutputSerialization', 'ParquetInputSerialization', 'QUOTE_FIELDS_ALWAYS', 'QUOTE_FIELDS_ASNEEDED', 'SelectObjectReader', 'SelectRequest', 'Stats', 'SubElement', 'absolute_import', 'abstractmethod', 'crc32', 'dataclass', 'findtext']
silo/signer.py ADDED
@@ -0,0 +1,26 @@
1
+ """Compatibility exports from minio.signer (minio 7.2.20)."""
2
+ from minio.signer import (
3
+ Credentials as Credentials,
4
+ DictType as DictType,
5
+ Mapping as Mapping,
6
+ OrderedDict as OrderedDict,
7
+ SIGN_V4_ALGORITHM as SIGN_V4_ALGORITHM,
8
+ SplitResult as SplitResult,
9
+ absolute_import as absolute_import,
10
+ annotations as annotations,
11
+ cast as cast,
12
+ datetime as datetime,
13
+ get_credential_string as get_credential_string,
14
+ hashlib as hashlib,
15
+ hmac as hmac,
16
+ post_presign_v4 as post_presign_v4,
17
+ presign_v4 as presign_v4,
18
+ queryencode as queryencode,
19
+ re as re,
20
+ sha256_hash as sha256_hash,
21
+ sign_v4_s3 as sign_v4_s3,
22
+ sign_v4_sts as sign_v4_sts,
23
+ time as time,
24
+ )
25
+
26
+ __all__ = ['Credentials', 'DictType', 'Mapping', 'OrderedDict', 'SIGN_V4_ALGORITHM', 'SplitResult', 'absolute_import', 'annotations', 'cast', 'datetime', 'get_credential_string', 'hashlib', 'hmac', 'post_presign_v4', 'presign_v4', 'queryencode', 're', 'sha256_hash', 'sign_v4_s3', 'sign_v4_sts', 'time']
silo/sse.py ADDED
@@ -0,0 +1,17 @@
1
+ """Compatibility exports from minio.sse (minio 7.2.20)."""
2
+ from minio.sse import (
3
+ ABC as ABC,
4
+ Any as Any,
5
+ Sse as Sse,
6
+ SseCustomerKey as SseCustomerKey,
7
+ SseKMS as SseKMS,
8
+ SseS3 as SseS3,
9
+ absolute_import as absolute_import,
10
+ abstractmethod as abstractmethod,
11
+ annotations as annotations,
12
+ base64 as base64,
13
+ cast as cast,
14
+ json as json,
15
+ )
16
+
17
+ __all__ = ['ABC', 'Any', 'Sse', 'SseCustomerKey', 'SseKMS', 'SseS3', 'absolute_import', 'abstractmethod', 'annotations', 'base64', 'cast', 'json']
silo/sseconfig.py ADDED
@@ -0,0 +1,24 @@
1
+ """Compatibility exports from minio.sseconfig (minio 7.2.20)."""
2
+ from minio.sseconfig import (
3
+ A as A,
4
+ ABC as ABC,
5
+ AES256 as AES256,
6
+ AWS_KMS as AWS_KMS,
7
+ B as B,
8
+ ET as ET,
9
+ Element as Element,
10
+ Optional as Optional,
11
+ Rule as Rule,
12
+ SSEConfig as SSEConfig,
13
+ SubElement as SubElement,
14
+ Type as Type,
15
+ TypeVar as TypeVar,
16
+ absolute_import as absolute_import,
17
+ annotations as annotations,
18
+ cast as cast,
19
+ dataclass as dataclass,
20
+ find as find,
21
+ findtext as findtext,
22
+ )
23
+
24
+ __all__ = ['A', 'ABC', 'AES256', 'AWS_KMS', 'B', 'ET', 'Element', 'Optional', 'Rule', 'SSEConfig', 'SubElement', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'find', 'findtext']
silo/tagging.py ADDED
@@ -0,0 +1,19 @@
1
+ """Compatibility exports from minio.tagging (minio 7.2.20)."""
2
+ from minio.tagging import (
3
+ A as A,
4
+ ET as ET,
5
+ Element as Element,
6
+ Optional as Optional,
7
+ SubElement as SubElement,
8
+ Tagging as Tagging,
9
+ Tags as Tags,
10
+ Type as Type,
11
+ TypeVar as TypeVar,
12
+ absolute_import as absolute_import,
13
+ annotations as annotations,
14
+ cast as cast,
15
+ dataclass as dataclass,
16
+ find as find,
17
+ )
18
+
19
+ __all__ = ['A', 'ET', 'Element', 'Optional', 'SubElement', 'Tagging', 'Tags', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'cast', 'dataclass', 'find']
silo/time.py ADDED
@@ -0,0 +1,25 @@
1
+ """Compatibility exports from minio.time (minio 7.2.20)."""
2
+ from minio.time import (
3
+ Optional as Optional,
4
+ absolute_import as absolute_import,
5
+ annotations as annotations,
6
+ ctime as ctime,
7
+ datetime as datetime,
8
+ from_http_header as from_http_header,
9
+ from_iso8601utc as from_iso8601utc,
10
+ timezone as timezone,
11
+ to_amz_date as to_amz_date,
12
+ to_float as to_float,
13
+ to_http_header as to_http_header,
14
+ to_iso8601utc as to_iso8601utc,
15
+ to_signer_date as to_signer_date,
16
+ utcnow as utcnow,
17
+ )
18
+
19
+ __all__ = ['Optional', 'absolute_import', 'annotations', 'ctime', 'datetime', 'from_http_header', 'from_iso8601utc', 'timezone', 'to_amz_date', 'to_float', 'to_http_header', 'to_iso8601utc', 'to_signer_date', 'utcnow']
20
+
21
+ # datetime.UTC only exists on newer Python versions; mirror upstream exactly.
22
+ import minio.time as _upstream_time
23
+ if hasattr(_upstream_time, "UTC"):
24
+ UTC = _upstream_time.UTC
25
+ __all__.append("UTC")
@@ -0,0 +1,25 @@
1
+ """Compatibility exports from minio.versioningconfig (minio 7.2.20)."""
2
+ from minio.versioningconfig import (
3
+ A as A,
4
+ DISABLED as DISABLED,
5
+ ENABLED as ENABLED,
6
+ ET as ET,
7
+ Element as Element,
8
+ List as List,
9
+ OFF as OFF,
10
+ Optional as Optional,
11
+ SUSPENDED as SUSPENDED,
12
+ SubElement as SubElement,
13
+ Type as Type,
14
+ TypeVar as TypeVar,
15
+ Union as Union,
16
+ VersioningConfig as VersioningConfig,
17
+ absolute_import as absolute_import,
18
+ annotations as annotations,
19
+ cast as cast,
20
+ dataclass as dataclass,
21
+ findall as findall,
22
+ findtext as findtext,
23
+ )
24
+
25
+ __all__ = ['A', 'DISABLED', 'ENABLED', 'ET', 'Element', 'List', 'OFF', 'Optional', 'SUSPENDED', 'SubElement', 'Type', 'TypeVar', 'Union', 'VersioningConfig', 'absolute_import', 'annotations', 'cast', 'dataclass', 'findall', 'findtext']
silo/xml.py ADDED
@@ -0,0 +1,25 @@
1
+ """Compatibility exports from minio.xml (minio 7.2.20)."""
2
+ from minio.xml import (
3
+ A as A,
4
+ B as B,
5
+ ET as ET,
6
+ Element as Element,
7
+ FromXmlType as FromXmlType,
8
+ Optional as Optional,
9
+ Protocol as Protocol,
10
+ SubElement as SubElement,
11
+ ToXmlType as ToXmlType,
12
+ Type as Type,
13
+ TypeVar as TypeVar,
14
+ absolute_import as absolute_import,
15
+ annotations as annotations,
16
+ find as find,
17
+ findall as findall,
18
+ findtext as findtext,
19
+ getbytes as getbytes,
20
+ io as io,
21
+ marshal as marshal,
22
+ unmarshal as unmarshal,
23
+ )
24
+
25
+ __all__ = ['A', 'B', 'ET', 'Element', 'FromXmlType', 'Optional', 'Protocol', 'SubElement', 'ToXmlType', 'Type', 'TypeVar', 'absolute_import', 'annotations', 'find', 'findall', 'findtext', 'getbytes', 'io', 'marshal', 'unmarshal']
@@ -0,0 +1,131 @@
1
+ Metadata-Version: 2.4
2
+ Name: silo-python-sdk
3
+ Version: 0.1.0
4
+ Summary: Unofficial Silo client preserving the MinIO Python SDK API
5
+ License-Expression: MIT
6
+ Requires-Python: >=3.9
7
+ Description-Content-Type: text/markdown
8
+ License-File: LICENSE
9
+ License-File: NOTICE
10
+ Requires-Dist: minio==7.2.20
11
+ Provides-Extra: test
12
+ Requires-Dist: pytest<10,>=8; extra == "test"
13
+ Dynamic: license-file
14
+
15
+ # Silo Python SDK
16
+
17
+ 面向 [PGSTY Silo](https://github.com/pgsty/silo) 的**非官方** Python SDK,复用官方 [MinIO Python SDK](https://github.com/minio/minio-py)。Python 3.9+。
18
+
19
+ ## 安装
20
+
21
+ 从本目录安装:
22
+
23
+ ```bash
24
+ python -m pip install .
25
+ ```
26
+
27
+ 或安装交付的 wheel:
28
+
29
+ ```bash
30
+ python -m pip install dist/silo_python_sdk-0.1.0-py3-none-any.whl
31
+ ```
32
+
33
+ 包名 `silo-python-sdk`,导入名 `silo`。尚未发布至 PyPI;安装时需要取得 `minio==7.2.20` 及其依赖。
34
+
35
+ ## 连接和迁移
36
+
37
+ ```python
38
+ import os
39
+ from silo import Silo
40
+ from silo.error import S3Error
41
+
42
+ client = Silo(
43
+ endpoint="localhost:9000", # host:port,不包含 http://
44
+ access_key=os.environ["SILO_ACCESS_KEY"],
45
+ secret_key=os.environ["SILO_SECRET_KEY"],
46
+ secure=False, # 仅本机 HTTP 实例;默认值为 True
47
+ )
48
+
49
+ if not client.bucket_exists("example"):
50
+ client.make_bucket("example")
51
+
52
+ client.fput_object("example", "hello.txt", "./hello.txt")
53
+ client.fget_object("example", "hello.txt", "./download.txt")
54
+ for obj in client.list_objects("example", recursive=True):
55
+ print(obj.object_name, obj.size)
56
+ ```
57
+
58
+ 迁移原代码时,将 `from minio import Minio` 换为 `from silo import Silo`,构造调用改为 `Silo(...)`;已有方法调用不变。辅助模块可把 `minio.commonconfig` 等改为 `silo.commonconfig`。`from silo import Minio` 也可用,它是上游原类。
59
+
60
+ `Silo` 继承 `Minio`,**63 个公开方法全部保持原方法、参数签名、返回类型和异常类型**,包括桶管理、对象操作、复制与合成、分片上传、删除、分页、版本控制、生命周期、访问策略、标签、通知、预签名 GET/PUT/POST、加密、对象锁、保留策略、法律保留、复制配置、Select、Snowball、append、prompt 等。25 个辅助模块的全部公开符号直接引用上游对象,包含 `credentials` 子模块、`minioadmin`、错误、配置和数据模型。
61
+
62
+ 完整清单和签名见 [docs/api-inventory.json](docs/api-inventory.json)。高级参数、凭据 Provider、session_token、自定义 http_client、region、cert_check 均沿用上游构造接口。管理类可从 `silo.minioadmin` 导入,SDK 并未承诺所有管理调用都能在 Silo 服务端执行。
63
+
64
+ 这份兼容承诺针对 **minio 7.2.20**。依赖固定该版本;升级时需重跑兼容及服务端测试。它不是独立重写的 S3 协议库。
65
+
66
+ ## 环境变量和便捷操作
67
+
68
+ ```bash
69
+ export SILO_ENDPOINT=localhost:9000
70
+ export SILO_ACCESS_KEY=silo-admin
71
+ export SILO_SECRET_KEY='填入实际密码'
72
+ export SILO_SECURE=false
73
+ ```
74
+
75
+ ```python
76
+ from silo import Silo
77
+
78
+ client = Silo.from_env()
79
+ client.upload_bytes("example", "folder/中文.txt", "你好 Silo".encode(), "text/plain")
80
+ content = client.download_bytes("example", "folder/中文.txt")
81
+ print(content.decode())
82
+ ```
83
+
84
+ 前三个变量必填,缺失或全空白抛出 `ValueError`;密钥原文保持不变。`SILO_SECURE` 默认 `true`,只接受 `true`/`false`(大小写不敏感,可带首尾空白),拼写错误报错。示例 `.env.example` 供参考,SDK 不自动读取 `.env` 文件。
85
+
86
+ `upload_bytes` 返回上游 `ObjectWriteResult`。`download_bytes` 在成功或异常时关闭响应并释放连接,内容全部读入内存。大文件、版本读取、加密和元数据操作请使用完整的上游 `put_object`、`get_object`、`fput_object`、`fget_object` 接口。例如:
87
+
88
+ ```python
89
+ response = client.get_object("example", "hello.txt", version_id="实际版本 ID")
90
+ try:
91
+ for chunk in response.stream(1024 * 1024):
92
+ print(len(chunk))
93
+ finally:
94
+ response.close()
95
+ response.release_conn()
96
+ ```
97
+
98
+ 异常原样传播,使用 `silo.error.S3Error` 或 `minio.error.S3Error` 捕获结果相同。客户端可在线程间共享;不可在多个进程间共享同一个实例,应每个进程独立创建。首次使用前自行创建目标桶;SDK 不修改既有桶策略。
99
+
100
+ ## 验证与限制
101
+
102
+ 完整对照核验见 [docs/compatibility-report.md](docs/compatibility-report.md):官方原版和 Silo 各有 114 项单元测试通过(2 项 locale 跳过),官方功能测试各有 49 项实执行通过(1 项 AWS 区域不适用)。官方功能测试新增实测了条件复制、预签名过期/响应头、线程读写、Select 和 Snowball;预签名 POST 仅生成策略,尚未实测 POST 上传。
103
+
104
+ API 保留和服务端支持是不同的保证。兼容测试遍历并检查所有方法和辅助符号;本机服务端测试覆盖:
105
+
106
+ - 创建/查询/删除桶,空字节和中文对象名,文件和字节上传下载。
107
+ - 元数据、范围读取、复制、合成,7 MiB 分片上传。
108
+ - 实际预签名 GET/PUT 请求,1005 个对象的跨页列举。
109
+ - 版本启用、指定版本读取、删除标记和版本清理。
110
+ - 生命周期配置、桶策略、桶/对象标签、空通知配置及相应删除操作。
111
+ - 未找到对象和错误凭据的真实 `S3Error`。
112
+
113
+ Python 3.9.25 和 3.13.3 上各有 67 项 SDK 测试通过;最低 Python 版本与原版一致为 3.9。
114
+
115
+ 实测对象为本机 Silo `RELEASE.2026-09-16T00-00-00Z`,HTTP、单节点。**未实测**外部身份 Provider、管理员 API、加密/KMS、对象锁/保留/法律保留、跨站复制、真实通知投递/监听、预签名 POST、append、prompt、AWS 加速/双栈、TLS、集群和故障恢复。这些接口仍完整保留,能否执行取决于服务端配置和功能支持。没有把兼容测试描述为这些功能的端到端证明。
116
+
117
+ ## 重跑测试和构建
118
+
119
+ ```bash
120
+ python -m pip install '.[test]' build
121
+ python -m pytest # 单元和兼容测试;跳过真实服务端测试
122
+ # 先设置上述四个 SILO_* 环境变量
123
+ python -m pytest --run-integration # 完整测试;缺少配置会报错
124
+ python -m build
125
+ ```
126
+
127
+ 集成测试使用随机 `silo-sdk-test-*` 桶,结束时删除本次生成的对象和桶;不会操作原有业务桶。验证证据见 `verification.json`。快速示例为 `examples/quickstart.py`;它保留新建示例桶和上传文件,便于在控制台查看。
128
+
129
+ ## 许可
130
+
131
+ 本包的封装代码采用 MIT。`minio` 是独立安装的 Apache-2.0 依赖,辅助模块仅导出其对象,没有复制上游实现。Silo 服务端为单独的软件项目,其许可不由本 SDK 改变。参见 LICENSE 和 NOTICE。
@@ -0,0 +1,34 @@
1
+ silo/__init__.py,sha256=weE38R1kpwP_ucr9YCpr5ylsMRXF1uJl1jH3cJPIUr0,218
2
+ silo/api.py,sha256=SI5nzKyukOALF66QglxgHqQKx3iSz-gRuDjcxa9UnDA,4702
3
+ silo/client.py,sha256=9u2xnnPqAtOpa0WRhDtAnrZXR9Q-dY-E7vDTGaPxfcs,2363
4
+ silo/commonconfig.py,sha256=eMGdq1GKv9Gg68QDpTdKdfnrSAlxxNWnNYmbR4gtoHk,1695
5
+ silo/crypto.py,sha256=HOWC4RM34oOZj5izFJgVZ5K_hh1RO5Hv9C7z6nEHaJ4,702
6
+ silo/datatypes.py,sha256=Z1Bz554_cQ7EdhA_FH7KoLiT7hmmsf1IQUaoAkvb4KY,2374
7
+ silo/deleteobjects.py,sha256=N30N1q5I8UR9Z3fiI5OEfd9f6j4LrHcu4e4Y_SWf3ug,865
8
+ silo/error.py,sha256=0mu7OOkoLxx9oRdr4amKELZ_45cnq9bT1Xm4NcPbZEk,726
9
+ silo/helpers.py,sha256=pvEGkHLSfWXinGKNEyDkw-FAyy6j76RAYnUTJYOrqUw,2632
10
+ silo/legalhold.py,sha256=qFclImlczxEBJyb8Td1l9V01o918tv_35N9S-R1lUtE,550
11
+ silo/lifecycleconfig.py,sha256=kh4lCL5vjL6IxB8kdYRSrMBiPG0r--n-jztsbKTra9Y,1426
12
+ silo/minioadmin.py,sha256=7LIpvm-7BHKkw8qQhOtjLCGgmAzS_Kpj2eh9lNuumCI,1532
13
+ silo/notificationconfig.py,sha256=np3JVDh1zEXtkj9G5SDlbcp_lQzvMy-rsE77eCQcRYA,1173
14
+ silo/objectlockconfig.py,sha256=mUc-AmVt-axLlmLa6aKideaQJOpfJqFzcVgNKG2X5Ok,815
15
+ silo/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
16
+ silo/replicationconfig.py,sha256=EA_eu9aCYFZZ4UQPU9BmjONXKYfyasfbZDPjnUKPhBI,1849
17
+ silo/retention.py,sha256=LRpnudUZ4svOpq6jHvwtNKAONUMkWdCxeXzKT7TSlck,814
18
+ silo/select.py,sha256=LFN5w5sMZN_9clhPePad0DuClC1kiy8EFCJRj9srFUY,2018
19
+ silo/signer.py,sha256=Al5QrssYmoyTUaqmnMDKzhSSBSJO6iT5j7S7f5EBebg,1024
20
+ silo/sse.py,sha256=Tp5lcC1ztCWXnERyepio2b_TIrMSGQGwopL8sNfNrr8,529
21
+ silo/sseconfig.py,sha256=Z9-WfY5XeRw-XGnQWHZSWV21WRBU5JOBOBGS0ifvmlk,735
22
+ silo/tagging.py,sha256=RefzzrpB6c6JQISdzczDa-1VCeumUhYQvT48lHxvJ0w,580
23
+ silo/time.py,sha256=-1TVQ5ExWSydRS3AEx1bXL-RhNXp39Ep8H4boISdL_A,956
24
+ silo/versioningconfig.py,sha256=gPDQAQ3zXVZyW0igdxAlH0V2lzTAEmJLZOvepQKPAjs,838
25
+ silo/xml.py,sha256=uRn8yEjJ5y8bio-mHK0twuudPVDFIOsNy5MdOcqQ-ho,794
26
+ silo/credentials/__init__.py,sha256=F0uNPYvaTB9IwsNkPT9l-Bi1MyHQpLd-jsu_O1uIjAM,1313
27
+ silo/credentials/credentials.py,sha256=WbuIaUTRUQcDx0p_Np6BMMyI9PyJ7iQkSjFwItOYMrI,427
28
+ silo/credentials/providers.py,sha256=X9OcnqmB4NcoCDmqlPPIEe9GtS3HKWCwUrl9uBy9Fts,2383
29
+ silo_python_sdk-0.1.0.dist-info/licenses/LICENSE,sha256=rWFdmFBm5xxaqg5pBYj8c4kCTHv9EU3UaTusAtGjTxw,1085
30
+ silo_python_sdk-0.1.0.dist-info/licenses/NOTICE,sha256=LKN03-IyCQYPKiHAAt_uk4tfBuyDdWrHW8O8YrClhmo,434
31
+ silo_python_sdk-0.1.0.dist-info/METADATA,sha256=ZA-_2gAgZoelkIIg9iZ7yuLsJL3a3f9LhuLi30h8OP4,6744
32
+ silo_python_sdk-0.1.0.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
33
+ silo_python_sdk-0.1.0.dist-info/top_level.txt,sha256=3PNbI_TTdp9a0jp9jnGP-svS20dJKfH-ipm5HNoDPuU,5
34
+ silo_python_sdk-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (84.0.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Silo Python SDK contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,7 @@
1
+ This is an unofficial Silo Python SDK. It is not endorsed by MinIO or PGSTY.
2
+ The package depends on minio 7.2.20, distributed separately under Apache-2.0.
3
+ Upstream: https://github.com/minio/minio-py
4
+ Upstream copyright: MinIO, Inc.
5
+ The compatibility modules re-export upstream objects; upstream implementation
6
+ source is not bundled in this distribution. Keep minio's own license and
7
+ notices with any redistribution of that dependency.
@@ -0,0 +1 @@
1
+ silo