DynamoDB value serialisation and deserialisation
Project description
DynamoDB value serialisation and deserialisation
Convert values from AWS DynamoDB to native Python types.
Makes more sensible decisions about numbers and binary values, at the cost of floating-point precision. Very lightweight.
Installation
pip install dynamodb-serialise
Usage
import dynamodb_serialise
dynamodb_serialise.deserialise(
{"M": {"foo": {"N": "42"}, "bar": {"B": "c3BhbQ=="}}}
)
# {'foo': 42, 'bar': b'spam'}
dynamodb_serialise.serialise(
{'foo': 42, 'bar': b'spam'}, bytes_to_base64=True
)
# {"M": {"foo": {"N": "42"}, "bar": {"B": "c3BhbQ=="}}}
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
Built Distribution
File details
Details for the file dynamodb-serialise-1.0.0.tar.gz
.
File metadata
- Download URL: dynamodb-serialise-1.0.0.tar.gz
- Upload date:
- Size: 6.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.4 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f61f94e72e2b942bbab6d380171e6d7842175130cc744eac3c23b9232057f045 |
|
MD5 | 9a077aa9a15de6ca4a9684ea55ecfa11 |
|
BLAKE2b-256 | f66636224a8381993d3442f862601b55daffe6b2e07e59636225c0afa3cd0775 |
File details
Details for the file dynamodb_serialise-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: dynamodb_serialise-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.4 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e61b973fdb058b3c0f10ff2c6cfac1455e0506c641250dabf0405aa2b62499be |
|
MD5 | f4bf2a9d7539a056f206e4920c8768e6 |
|
BLAKE2b-256 | 5035a721bd1f7066e071f1b136e5ddfa3e3bd3e36ea6e10b0dd046d44e5b5c72 |