minimalkv.net.boto3store module¶
- class minimalkv.net.boto3store.Boto3SimpleKeyFile(s3_object)¶
Bases:
RawIOBase
- read(size=-1)¶
- readable() bool ¶
Return whether object was opened for reading.
If False, read() will raise OSError.
- seek(offset: int, whence=0) int ¶
Change the stream position to the given byte offset.
- offset
The stream position, relative to ‘whence’.
- whence
The relative position to seek from.
The offset is interpreted relative to the position indicated by whence. Values for whence are:
os.SEEK_SET or 0 – start of stream (the default); offset should be zero or positive
os.SEEK_CUR or 1 – current stream position; offset may be negative
os.SEEK_END or 2 – end of stream; offset is usually negative
Return the new absolute position.
- class minimalkv.net.boto3store.Boto3Store(bucket, prefix: str | None = None, object_prefix: str = '', url_valid_time: int = 0, reduced_redundancy: bool = False, public: bool = False, metadata=None, create_if_missing=False)¶
Bases:
KeyValueStore
,UrlMixin
,CopyMixin
- minimalkv.net.boto3store.map_boto3_exceptions(key=None, exc_pass=())¶
Map boto3-specific exceptions to the minimalkv-API.