Skip to main content

Build Status Code Coverage Issue Count

S3 Cache for Python

Niall McCarroll wrote a neat little AWS S3 cache on his blog that I found really useful, but could not find on PyPI, so here it is in a refactored form as a public service.

Instructions

from s3cache import S3Cache

s3 = S3Cache("/tmp", "t13d-misc")
s3.connect()
s3.create_bucket()
assert(s3.bucket_exists())

s3.set_verbosity(True)
s3.set_caching(True)

f = s3.open("/tmp/world.txt", "w")
f.write("Hello")
f.close()

f = s3.open("/tmp/world.txt", "a")
f.write(" World")
f.close()

f2 = s3.open("/tmp/world.txt", "r")
f2.close()

assert(s3.object_exists("/tmp/world.txt"))
s3.remove_object("/tmp/world.txt")

References

  1. A local file cache for amazon S3 using python and boto

Release files for s3cache 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for s3cache 0.1.1
File Size Uploaded
s3cache-0.1.1.tar.gz 4.9 kB Details

Release files / s3cache-0.1.1.tar.gz

Download URL s3cache-0.1.1.tar.gz
Size 4.9 kB
Tags Source
SHA-256 checksum
How to use checksums
f1f82db4c08de0f38d416b273fdbb47d876cb65ca3961da0bd0e897c59ac96e0
BLAKE2b-256 checksum
How to use checksums
b7f7bd1ceea00e7abc31d84ac5cceaa63953a0d777a764108a52bd60a29decf8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.1 This release

1 release file

0.1.0

1 release file

0.1.0rc1

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page