Skip to main content

No project description provided

Project description

gloomy

"glom but not as slow"

An utility for retrieving values from deeply nested object attributes, mapping keys, sequence indexes, or any combination of them.

Not meant as a drop in replacement for glom, only basic functionality is implemented.
A good use-case would be to improve existing codebases in which the glom pattern is commonly used for convenience, as it can significantly affect performance.

Usage

from gloomy import gloom

assert gloom({"a": {"b": {"c": [123]}}}, "a.b.c.0") == 123

# Or with a default in case the path is invalid
assert gloom({}, "a.b.c", default=None) is None

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

gloomy-0.1.0.tar.gz (13.5 kB view details)

Uploaded Source

Built Distribution

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

gloomy-0.1.0-py3-none-any.whl (3.0 kB view details)

Uploaded Python 3

File details

Details for the file gloomy-0.1.0.tar.gz.

File metadata

  • Download URL: gloomy-0.1.0.tar.gz
  • Upload date:
  • Size: 13.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.3

File hashes

Hashes for gloomy-0.1.0.tar.gz
Algorithm Hash digest
SHA256 94fc63227da8be3da14ddb6abc0b104005a42311af198f32e52d9f9c92aa8daa
MD5 fafb0a9bd68b4c394a24dfab29a393a9
BLAKE2b-256 e8c43c6babe33ea0c19122477f3b093b3dd2295fa2f7b6c0643469738918c7ce

See more details on using hashes here.

File details

Details for the file gloomy-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: gloomy-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.3

File hashes

Hashes for gloomy-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1f975c5d08adbd428e738c1403c1cf73f80fb02f6d3fb7564c7efbcf415f963b
MD5 7839d6e53531b13e277e0c7e7fa6d93f
BLAKE2b-256 e71eb100ec70c9ea98008ffdb23c26d7a3a5d29f0350160a36fe4a2c89c6d6e9

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