Skip to main content

Manage files in bulk quantity using a friendly dict-like interface

Project description

File-Storehouse

Test and build Code style: black python PyPI Version

Main Features

File-Storehouse is a lightweight Python package that aims to facilitate the management of files in bulk quantity.

There are four key points that are combined to achieving such a goal:

  • Mapping Interface - The file managers are leveraged by the Mapping and MutableMapping interfaces, which means that everything can be done using a friendly dict-like interface. For instance:

    # Store data to a file:
    file_manager[id] = file_content
    # Retrine data from a file
    file_content = file_manager[id]
    # Delete a file
    del file_manager[id]
    # Loop through all files
    for id, content in file_manager.items():
        pass
    # and many more...
    
  • Engine - Choose the engine (or back-end) your file managers are connected to:

    • S3 buckets, powered by boto3;
    • Local filesystem and more are planned.
  • Key Mapping - Customize a two-way key mapping between the dict-like keys and the files' location at the engines according to the business rules of your application.

  • Transformations - Configure a chained operation to convert the files back and forward between your Python code and the storage. The supported operations are:

    • Encode/decode bytes and strings;
    • Dump/load Json files;
    • Compress/decompress tarballs and more transformations are planned.

Example

Please, take a look at the user story used for testing.

Copyright and License

© 2022 Felipe N. Schuch. All content is under MIT License.

Project details


Download files

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

Source Distribution

file-storehouse-0.5.0.tar.gz (8.3 kB view hashes)

Uploaded Source

Built Distribution

file_storehouse-0.5.0-py3-none-any.whl (13.5 kB view hashes)

Uploaded Python 3

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