Python dict with Deta backend
Project description
detadict
Goal: create dictionary that fully compatible with native python dictionary interface.
Example:
from detadict import detadict
users = detadict()
users["John"] = {
"id": 1,
"sex": "male"
}
users["Katy"] = {
"id": 2,
"sex": "female"
}
Requirements:
🤦♂️ All you need to do is set the environment variable DETA_PROJECT_KEY
with the Deta project key.
Currently not supported:
- Update of mutable values
users["John"]["sex"] = "female"
print(users["John"]) # {"id": 1, "sex": "male"}
copy
andsetdefault
methods
# raise NotImplementedError
users.copy()
users.setdefault("Bob", {})
Installing:
pip install detadict
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
detadict-0.1.0.tar.gz
(3.1 kB
view details)
Built Distribution
File details
Details for the file detadict-0.1.0.tar.gz
.
File metadata
- Download URL: detadict-0.1.0.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.8 CPython/3.7.12 Linux/5.10.16.3-microsoft-standard-WSL2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0dd3ce6c8dead2bb4461cee57792cbf953b8753dfdc1e066bb9be21e3049f244 |
|
MD5 | 2b302b9ccfe36b804c4a78ea33e5df6c |
|
BLAKE2b-256 | 4e6bdc7b53766a5c9e60fd2fa5578832db42374941ff828d51d5e308ea9a4658 |
File details
Details for the file detadict-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: detadict-0.1.0-py3-none-any.whl
- Upload date:
- Size: 3.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.8 CPython/3.7.12 Linux/5.10.16.3-microsoft-standard-WSL2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c3612932ca574b35872276efacf7ec406bf60d30d54a09a84833be6e8bd604d7 |
|
MD5 | 27e0c4644191ab90936284e10ddbc5a1 |
|
BLAKE2b-256 | fb9fdef885640135297003aae34b65b521ad2f4fbad1e91dad4f96fd4e589eda |