🚀 aiodoc: Async ByteIO Retrieval from Any Source 🪣
Welcome to aiodoc! 🎉 This library allows you to retrieve BytesIO objects from various sources asynchronously. Whether you're dealing with cloud storage, HTTP endpoints, FTP servers, or local files, aiodoc has got you covered! 🌐
🎯 Key Features
- Async all the way 🌟: Perform all file operations asynchronously to keep your application responsive.
- Retrieve from any source 🔌: Supports AWS S3, MinIO, Google Cloud Storage, HTTP, FTP, Redis, Memcached, and even local file systems.
- Unified API 🤹: A simple, easy-to-use interface for interacting with any storage system.
💼 Supported Providers
- 🐘 AWS S3 via
aiobotocore🚀 - 🦒 MinIO using
minio-py🛠️ - ☁️ Google Cloud Storage with
google-cloud-storage🎩 - 🌐 HTTP with
httpx🌍 - 📂 Local file system with
aiofile🗂️ - 🧠 Memcached using
aiomemcached🧳 - 🔥 Redis via
aioredis🔥 - 🔗 FTP with
aioftp📡
🎒 How to Install
-
Clone the repo:
git clone https://github.com/your-repo/aiodoc.git
-
Install dependencies:
pip install -r requirements.txt
-
Done! 🎉 Now you're ready to use
aiodocfor all your asynchronous file needs.
🛠️ Usage
🎩 Create Your Provider
You can set up and use different providers based on your needs.
🐘 AWS S3 Example
from aiobotocore.session import AioSession
from aiodoc import S3Provider
# Initialize S3 provider
session = AioSession()
s3_provider = S3Provider(session)
# Retrieve a file as a BytesIO object
file_bytes = await s3_provider.download("my-bucket", "my-file.txt")
☁️ Google Cloud Storage Example
from google.cloud import storage
from aiodoc import GCPProvider
# Initialize GCP provider
client = storage.Client()
gcp_provider = GCPProvider(client)
# Retrieve a file as a BytesIO object
file_bytes = await gcp_provider.download("my-bucket", "my-file.txt")
📂 Local File System Example
from aiodoc import FileProvider
# Initialize File provider
file_provider = FileProvider()
# Retrieve a file as a BytesIO object
file_bytes = await file_provider.download("bucket", "/path/to/file.txt")
🔥 Redis Example
from aioredis import Redis
from aiodoc import RedisProvider
# Initialize Redis provider
redis_client = await Redis.create()
redis_provider = RedisProvider(redis_client)
# Retrieve a file as a BytesIO object
file_bytes = await redis_provider.download("bucket", "file-key")
🛠️ Available Operations
- Upload 🆙: Upload a
BytesIOobject to any provider. - Download ⬇️: Retrieve a
BytesIOobject from any provider. - List Files 📜: List files (where supported).
- Delete File ❌: Delete a file (where supported).
🤝 Contributing
Feel free to submit issues or pull requests if you'd like to contribute!
📝 License
This project is licensed under the MIT License.
Metadata
Release files for aiodoc 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| aiodoc-0.1.2.tar.gz | 6.1 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| aiodoc-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.3 kB
Release files / aiodoc-0.1.2.tar.gz
| Download URL | aiodoc-0.1.2.tar.gz |
|---|---|
| Size | 6.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
972b94ba172de0032b285e1385ec37806015d437293a0d067b12954a3b488b49
|
|
BLAKE2b-256 checksum How to use checksums |
76fe9ffa249ac90c72a5362de1ff7420a3d97f95a77a4b2435bf8aadefb72ba1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.7
|
Release files / aiodoc-0.1.2-py3-none-any.whl
| Download URL | aiodoc-0.1.2-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f6cd6754b355150607f3637ee967093180a927e86db3b23f9c8211f72f604f1
|
|
BLAKE2b-256 checksum How to use checksums |
e85dde38cf789f016bf68b75b0b4c839d969c1c69ba8c8fa003f4cac764ee9dd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.7
|
Security for aiodoc 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.