Durango
Durango is a lightweight configuration management toolkit that layers strongly typed settings, configuration files, environment variables, and programmatic overrides using Pydantic Settings. It is designed for CLI tools and services that need predictable precedence, multi-format config files, and clear error reporting.
Key Features
- Config precedence: defaults → config file → environment variables → user overrides.
- Format flexibility: parse YAML, JSON, or TOML files by default with optional extras.
- Typed settings: describe your configuration with Pydantic models and receive fully validated objects.
- Reload aware: refresh configuration at runtime and hook into lifecycle callbacks.
- Extensible: adapt environment prefixes, merge behaviour, and file lookup strategies to fit your application.
Installation
Durango is published on PyPI as durango. Install it with your preferred tool:
# Using uv (recommended)
uv add durango
# Using pip
pip install durango
Durango supports Python 3.9 through 3.12.
Quick Start
from durango import ConfigManager, DurangoSettings
class AppSettings(DurangoSettings):
debug: bool = False
api_url: str
manager = ConfigManager(
settings_type=AppSettings,
identifier="MYAPP",
default_file="~/.config/myapp/settings.yaml",
)
settings = manager.load()
print(settings.api_url)
If ~/.config/myapp/settings.yaml does not exist, Durango will create it and populate it with the model defaults before layering environment variables and runtime overrides.
Environment variables take the form MYAPP__API_URL=true. To override a nested section named database, use MYAPP__DATABASE__URL.
Documentation
- Docs site (WIP): see
docs/ - Architecture notes:
ARCH.md - Working session notes:
notes/STATUS.md
Contributing
See docs/contributing.md for full setup, workflow, and review guidelines. Highlights:
- Install dependencies with
uv sync --all-extras --dev. - Run
uv run invoke cibefore opening a pull request. - Publishing and release automation are covered in docs/publishing.md.
License
Durango is available under the MIT License. See LICENSE for details.
Metadata
Release files for durango 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| durango-0.1.3.tar.gz | 329.1 kB | Without provenance | Details for durango-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| durango-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for durango-0.1.3-py3-none-any.whl |
Total release size: 344.4 kB
Release files / durango-0.1.3.tar.gz
| Download URL | durango-0.1.3.tar.gz |
|---|---|
| Size | 329.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
85727beeddf9c617ccc65b8b46bb7380c9805c5b4a8f085275254a68aa8027ba
|
|
BLAKE2b-256 checksum How to use checksums |
bd85ddf76a5c130b8d3b45feed4cfc040f23df3cd3927965cf9e8d6e91575d7d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.19
|
Release files / durango-0.1.3-py3-none-any.whl
| Download URL | durango-0.1.3-py3-none-any.whl |
|---|---|
| Size | 15.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
99ed0099cb8ec523202aa2bed3cedd96f3de99e1c80b900ecf71a284a8ae3cc5
|
|
BLAKE2b-256 checksum How to use checksums |
2d5d4210d1e37d66717561feedc7de3b86241a465cda7e549651dd720617b10e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.19
|
Security for durango 0.1.3
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.