Skip to main content

A dict that does not support None entries. Silently deletes entry if updated to null and works recursively.

Project description

NeverNoneDict

Python Dictionary that does not have None values.

Installing

You can start using nn dict by installing it using pip.

pip install nndict

Using nndict

>nndict_ = nndict({"a": 2, "b": None, "c": {"d": None}})
>print(nndict_)
{'a': 2, 'c': {}}

>nndict_ = nndict({"a": 2})
>print(nndict_)
{'a': 2}

>nndict_["a"] = None
>print(nndict_)
{}

Running the tests

Make sure you have the python versions listed in tox.ini installed. Then run tox:

tox

Authors

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

nndict-2.0.1.tar.gz (2.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nndict-2.0.1-py3-none-any.whl (2.8 kB view details)

Uploaded Python 3

File details

Details for the file nndict-2.0.1.tar.gz.

File metadata

  • Download URL: nndict-2.0.1.tar.gz
  • Upload date:
  • Size: 2.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.7.7 Linux/5.13.0-37-generic

File hashes

Hashes for nndict-2.0.1.tar.gz
Algorithm Hash digest
SHA256 3781bdd3deb42d9e4492392f3ab9324d11d14810d1f766c2622140d85e5cc00d
MD5 c9889ad1731034224b3290ccf4900602
BLAKE2b-256 12e67056339d495ff63084911280b7e7fc97e792ce22bf71a201b407301bccd1

See more details on using hashes here.

File details

Details for the file nndict-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: nndict-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 2.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.7.7 Linux/5.13.0-37-generic

File hashes

Hashes for nndict-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 841a86513f74feffc7151c360b0d5c4f3673cebaf0e68691312d4990a3a270fc
MD5 6b6bb380d315302eacabbbf47f6b7795
BLAKE2b-256 f8b8734789cda8bd60823d42ff21c80f457f839f052502e8eab239d01fe9f388

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page