DataDelve
Working with complex nested data can be tedious. If you have to access any objects that are four layers deep in a JSON response from a web service, you quickly tire of writing square brackets. Much better would be to have a simple way of accessing data through a simple syntax. jsonpointer is a perfect match, it looks just like paths through a filesystem. Applying this information to the data structures makes it easy and convenient.
Usage
from datadelve import DataDelver
data = ["your annoying data here"]
delver = DataDelver(data)
element = delver.get("/dict/keys/and/1/list/index")
subset = delver.cd("/particular/key/to/focus/on")
delver.set("/path/to/change", "new")
delver.delete("/bad")
Support
This package grew around a series of JSON files, so that is the primary focus. It therefore
expects data structures with dicts and lists. As the implementation is turned over to
jsonpointer, it will work for anything that implements __getitem__(str) or that is registered
as a collections.abc.Sequence and implements __getitem__(int).
Raw data, loaded from whatever source, is accepted. So are JSON files. These have the added benefit of being flyweight instances, so all views on the same file reference the same object. This way none of them can get out of sync and make writes indeterminate as to what updates have actually been made. As YAML isn't in the standard library, I've split support for that into a separate project: datadelve_yaml. YAML files are treated the same as JSON.
Metadata
Release files for datadelve 0.8.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 | Provenance | |
|---|---|---|---|---|
| datadelve-0.8.4.tar.gz | 14.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| datadelve-0.8.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 28.6 kB
Release files / datadelve-0.8.4.tar.gz
| Download URL | datadelve-0.8.4.tar.gz |
|---|---|
| Size | 14.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9c8846faaa7a54566fc7c7de837f20d0c6db2c30122fca7f8fdf7ee9830c48d6
|
|
BLAKE2b-256 checksum How to use checksums |
e3705ba019e0691fd056e37b7d8fe944cd2a150f7966e6f95551823947ab0229
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.1 CPython/3.8.10 Linux/5.4.0-125-generic
|
Release files / datadelve-0.8.4-py3-none-any.whl
| Download URL | datadelve-0.8.4-py3-none-any.whl |
|---|---|
| Size | 14.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d5b32db7f40612842e85218bc240a66400a734db47791ea2656f3937c67e04ee
|
|
BLAKE2b-256 checksum How to use checksums |
09d415e1612fe74ae7880d4d7765d7eb570ecba1fb946da73b2cc26a5d08eed6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.1 CPython/3.8.10 Linux/5.4.0-125-generic
|
Security for datadelve 0.8.4
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.