python-jsonargparse
Port variant v12
Summary JSON argument and config file parser (3.12)
BROKEN
Package version 4.32.1
Homepage No known homepage
Keywords python
Maintainer Python Automaton
License Not yet specified
Other variants v11
Ravenports Buildsheet | History
Ravensource Port Directory | History
Last modified 07 SEP 2024, 17:00:23 UTC
Port created 07 JAN 2023, 04:18:24 UTC
Subpackage Descriptions
single jsonargparse ============ Docs: https://jsonargparse.readthedocs.io/ | Source: https://github.com/omni-us/jsonargparse/ jsonargparse is a library for creating command-line interfaces (CLIs) and making Python apps easily configurable. It is a well-maintained project with frequent releases, adhering to high standards of development: semantic versioning, deprecation periods, changelog, automated testing, and full test coverage. Although jsonargparse might not be widely recognized yet, it already boasts a [substantial user base ]. Most notably, it serves as the framework behind pytorch-lightning's [LightningCLI ]. Features -------- jsonargparse is user-friendly and encourages the development of **clean, high-quality code**. It encompasses numerous powerful features, some unique to jsonargparse, while also combining advantages found in similar packages: - **Automatic** creation of CLIs, like [Fire ], [Typer ], [Clize ] and [Tyro ]. - Use **type hints** for argument validation, like [Typer ], [Tap ] and [Tyro ]. - Use of **docstrings** for automatic generation of help, like [Tap ], [Tyro ] and [SimpleParsing ]. - Parse from **configuration files** and **environment variables**, like [OmegaConf], [dynaconf ], [confuse ] and [configargparse ]. - **Dataclasses** support, like [SimpleParsing ] and [Tyro ]. Other notable features include: - **Extensive type hint support:** nested types (union, optional), containers (list, dict, etc.), user-defined generics, restricted types (regex, numbers), paths, URLs, types from stubs (``*.pyi``), future annotations (PEP [563 ]), and backports (PEPs [604 ]/[585 ]). - **Keyword arguments introspection:** resolving of parameters used via ``**kwargs``. - **Dependency injection:** support types that expect a class instance and callables that return a class instance. - **Structured configs:** parse config files with more understandable non-flat hierarchies. - **Config file formats:** [json], [yaml ], [jsonnet] and extendible to more formats. - **Relative paths:** within config files and parsing of config paths referenced inside other configs. - **Argument linking:** directing parsed values to multiple parameters, preventing unnecessary interpolation in configs. Design principles ----------------- - **Non-intrusive/decoupled:** There is no requirement for unrelated modifications throughout a codebase, maintaining the [separation of concerns principle ]. In simpler terms, changes should make sense even without the CLI. No need to inherit from a special class, add decorators, or use CLI-specific type hints.
Configuration Switches (platform-specific settings discarded)
PY311 OFF Build using Python 3.11 PY312 ON Build using Python 3.12
Package Dependencies by Type
Build (only) python312:dev:std
python-pip:single:v12
autoselect-python:single:std
Build and Runtime python312:primary:std
Runtime (only) python-PyYAML:single:v12
Download groups
main mirror://PYPIWHL/0c/d4/dbe0bcf04bc0cd172eb4c286992f1a1b0a9db5e7a1e503ecc9c067f0e2d3
Distribution File Information
fdf4c043ceb8efe3e4ae626d33359084615e6272274552930b25398fba902d73 207323 jsonargparse-4.32.1-py3-none-any.whl
Ports that require python-jsonargparse:v12
python-netbox-agent:v12 NetBox agent for server (3.12)