Skip to main content

S3 wrapper built on top of `boto3`.

Project description

ezS3

This library provides abstractions over boto3 to easily deal with S3 buckets.

Usage

from ezs3 import S3

s3 = S3(bucket_name="some_bucket")

# upload everything in `./data` to `bucket_name://data/input`, imitating the
# directory structure. the directory `data` itself is not copied.
# these are equivalent:
#   s3.upload("./data", "data/input")
#   s3.upload("./data/", "data/input/")
s3.upload("./data/", "data/input")
# upload `/tmp/my_file` to `bucket_name://data/my_file`.
s3.upload("/tmp/my_file", "data/")

# download everything under `bucket_name://data/input` into `./data2`,
# imitating the prefix structure.
s3.download("data/input", "./data2/")
# download `bucket_name://data/my_file` into `/tmp`.
s3.download("data/my_file", "/tmp/")
# same as above, but file is renamed to `my_file2`.
s3.download("data/my_file", "/tmp/my_file2")

# remove files.
s3.remove(*s3.list_keys("data/"))

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

ezs3-0.1.0-py3-none-any.whl (15.8 kB view details)

Uploaded Python 3

File details

Details for the file ezs3-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: ezs3-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 15.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7

File hashes

Hashes for ezs3-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 544b013d9a8b97e0650022b4b6a5fe21d68ec2abb897370415073b2472841f69
MD5 3470a508281b2c68e6e106b573b92c5d
BLAKE2b-256 cd27d48de1c2a4d848cf1d044f26cdb54e3206f5ffcbcf3bd393152680f8cab0

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page