skillfed

dictor

an elegant dictionary and JSON handler

dictor v0.1.12 570.7K downloads/30d#5,954 on PyPI76
Permissive license MIT DORMANT released

What it is and what it does

Dictor is a dictionary and JSON navigation utility that abstracts away the boilerplate of nested key lookups and exception handling. Instead of chaining dict.get() calls or writing try/except blocks to safely traverse nested structures, you pass a dot-separated path string to dictor() and receive the value at that location—or a fallback value if the key is missing. It handles lists within dicts, dicts within lists, case-insensitive key matching, custom path separators for keys containing dots, and key-based search across entire structures.

The package solves a common pain point in JSON and dictionary processing: safely extracting values from complex, unpredictable nested structures without defensive coding. It is most useful when parsing API responses, configuration files, or other external JSON data where the structure may vary or keys may be absent. No runtime dependencies means it installs cleanly into any Python environment.

Use it for:

  • Extract nested values from API responses without repeated try/except blocks or chained .get() calls.
  • Parse configuration files or JSON data with optional or variable structure, using fallback defaults.
  • Search for all occurrences of a specific key across a deeply nested dictionary or list-of-dicts structure.
  • Access list elements by index within a nested path (e.g., 'characters.Lonestar.items.0').
  • Handle keys containing dots or special characters by using a custom path separator or escape sequences.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Dictor provides a simplified interface for navigating and extracting values from nested dictionaries and JSON structures using dot-separated path notation, with built-in fallback handling for missing keys.

Yes, if you frequently work with nested JSON or dictionary structures and want to reduce boilerplate. No, if you need active maintenance—the project is dormant with last release on 2023-09-15. The high install friction (source-only distribution) is a minor drawback but not a blocker for most use cases.

Install

dictor on PyPI

pip

pip install dictor

uv

uv add dictor

poetry

poetry add dictor

Installing dictor

Before you install

High install friction due to source-only distribution (no wheels). Maintenance is dormant—last release was 2023-09-15, though the repository remains active with a recent commit in 2023-09-19. No runtime dependencies.

License in practice

MIT license is permissive and places no restrictions on use, modification, or redistribution in commercial or private projects.

Quickstart

pip install dictor

from dictor import dictor
import json

data = {"characters": {"Lonestar": {"id": 55923, "items": ["space winnebago"]}}}
print(dictor(data, 'characters.Lonestar.items.0'))

Python 2 support is being dropped in version 0.1.13 and later; verify your Python version compatibility if pinning to an older release.

Verify before relying

  • Whether version 0.1.13 or later (with Python 2 support removed) has been released, given the fact sheet shows 0.1.12 as current.
  • Actual Python version support range for the current release (requires_python is empty in metadata).
  • Performance characteristics when handling very large nested structures or deeply nested paths.

Package facts

License MIT (permissive)
Python support not specified
Install friction high — source build required
Runtime dependencies none
Maintenance dormant — 1,064 days since the last release
Last repo commit
First released
Downloads 570,744/month — #5,954 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: dictor-0.1.12.tar.gz

Tags

nested dictionary accessjson path lookupsafe dict key retrievaldeep nested dict navigationjson structure parsingdictionary traversal helpermissing key fallback
json-parsingdict-utilities

More Utilities packages