Skip to main content

Python Immutable Dict

badge

This library contains the ImmutableDict, a Python dictionary which can't be updated.

How to use it

  1. Install it from pip

pip install adaendra-immutable-dict

  1. Import the AdaendreImmutableDict

from adaendra_immutable_dict.AdaendraImmutableDict import AdaendraImmutableDict

  1. Use it like in the following examples.

Examples

from adaendra_immutable_dict.AdaendraImmutableDict import AdaendraImmutableDict

# Empty Immutable Dict
immutable_dict = AdaendraImmutableDict({})

# Non empty Immutable Dict
immutable_dict = AdaendraImmutableDict({"hello": "world"})

# Get a value
immutable_dict["hello"]
#> world

# Copy dict
immutable_dict_copy = immutable_dict.copy()

# Create an immutable dict from "fromkeys" method
immutable_dict = AdaendraImmutableDict.fromkeys(["a", "b"], "1")

Documentation


Credits

This project is based on Marco Sulla's project: frozen-dict.

Metadata

Release files for adaendra-immutable-dict 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for adaendra-immutable-dict 1.0.0
File Size Uploaded Provenance Actions
adaendra_immutable_dict-1.0.0.tar.gz 15.9 kB Without provenance Details for adaendra_immutable_dict-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for adaendra-immutable-dict 1.0.0
File Interpreter ABI Platform Actions
adaendra_immutable_dict-1.0.0-py3-none-any.whl Python 3 none any Details for adaendra_immutable_dict-1.0.0-py3-none-any.whl

Total release size: 32.3 kB

Release files / adaendra_immutable_dict-1.0.0.tar.gz

Download URL adaendra_immutable_dict-1.0.0.tar.gz
Size 15.9 kB
Tags Source
SHA-256 checksum
How to use checksums
bff88d05fe9bbcade7b3ffbb96114eda3ce82dbeb6824a68aafcf16ccabfc6d9
BLAKE2b-256 checksum
How to use checksums
6a7b1d1320b924197e5a417ba292b112e44d427fd688f612b8de8444c2e213e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

Release files / adaendra_immutable_dict-1.0.0-py3-none-any.whl

Download URL adaendra_immutable_dict-1.0.0-py3-none-any.whl
Size 16.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a77b6f38884b0e3f475d681ae7497e4e7bf28674c76cddf730e3ffa2e1ea59ef
BLAKE2b-256 checksum
How to use checksums
3da5f57c97930c32aa2dd72aa5db39efe4cb38bb1d560ab0a7ccf454d7e33021
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

Security for adaendra-immutable-dict 1.0.0

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page