Magic Container
Thread-safe, lightweight and persistent dict for Python with a magical touch.
Contents
Installation:
pip install magic-container
Examples:
Use it like a dict:
from container import container
container["key"] = 3
print(container["key"])
del container["key"]
Or get the values while setting them if there aren't in the container:
from container import container
print(container["second_key"], lambda: 23)
Limitations:
- Currently only works if installed and used in a virtual environment with write access to the venv folder.
- Currently keys can only be strings.
- Currently only the
get,setanddeletemethods are defined.
Metadata
Release files for magic-container 0.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| magic-container-0.0.4.tar.gz | 3.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| magic_container-0.0.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 6.9 kB
Release files / magic-container-0.0.4.tar.gz
| Download URL | magic-container-0.0.4.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f0ddbe9eab64af78cce2dc41f07b29c36926e9857e9ba7a3067192efed2c6bb6
|
|
BLAKE2b-256 checksum How to use checksums |
02e608a452bab546c711ab7c9d181ab370f72b865ff34057025c9f10a67b9450
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.10
|
Release files / magic_container-0.0.4-py3-none-any.whl
| Download URL | magic_container-0.0.4-py3-none-any.whl |
|---|---|
| Size | 3.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b5223da4fa4e3a78fb34b40bfd43fe81d5a48bb27f9b73d20237781e9db51def
|
|
BLAKE2b-256 checksum How to use checksums |
5bc7cae709309ac64bc4ce9f704c8e44b4cc3cd98c735bf07c076faa5bad1f30
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.10
|