Simple, transparent on-disk JSON store
Project description
mrjsonstore
Simple, transparent on-disk JSON store using atomicwrites
.
store = JsonStore('example.json')
with store() as x:
assert isinstance(x, dict)
x['woohoo'] = 'I am just a Python dictionary'
Changes are written on context exit, regardless of exceptions that occurred.
Unless a transaction is used:
with store.transaction() as x:
[ ... ]
raise RuntimeError()
In that case any changes are rolled back on context exit.
Does not yet support concurrency.
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
mrjsonstore-0.4.0.tar.gz
(5.8 kB
view hashes)
Built Distribution
Close
Hashes for mrjsonstore-0.4.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e6c341b2be970a3bb3deabd54cfa33029a8e1ffabee726e38130172d099224fa |
|
MD5 | ac82b5a0183ab8b88f67a47a2a84dd7c |
|
BLAKE2b-256 | ddb9dac71f00913a98ae9c6550c42148e04cdfb142ae883561386020502fe958 |