Skip to main content

No project description provided

Project description

SafeDict

SafeDict is a Python library providing a safe way to access nested dictionary keys with default handling for missing or None values.

Installation

pip install safe-dict

Usage

from safe_dict import SafeDict

data = SafeDict({"a": {"b": 1}})
print(data["a"]["b"])  # Output: 1
print(data["a"]["c"])  # Output: {}

LICENSE

Thêm một license (ví dụ MIT). Bạn có thể lấy mẫu MIT License.

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

safe_dict-1.0.1.tar.gz (2.0 kB view details)

Uploaded Source

Built Distribution

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

safe_dict-1.0.1-py3-none-any.whl (2.6 kB view details)

Uploaded Python 3

File details

Details for the file safe_dict-1.0.1.tar.gz.

File metadata

  • Download URL: safe_dict-1.0.1.tar.gz
  • Upload date:
  • Size: 2.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for safe_dict-1.0.1.tar.gz
Algorithm Hash digest
SHA256 ea3cdb39d71a2e37e4f201d2559d46a7ddd665e34e3aaf2cf87e0fade80e8d10
MD5 551c148f55c52b8d2046354ebc353ed0
BLAKE2b-256 9a58e6fb93b26107afa0af3bb6ca95eb2950567e8c47f787626036f4190336bc

See more details on using hashes here.

File details

Details for the file safe_dict-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: safe_dict-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 2.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for safe_dict-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0e809b6d9c1d768b4a1bd73123d486833fc39dc7099eb85a0eb3faac632a3429
MD5 6059505abd8f0b3630c5d8ad08e72b09
BLAKE2b-256 877f3744106d3633c573cdab7750d9559b8da2398096f9f6cffbbb6496388ada

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