typed-argument-parser
typed-argument-parser copied to clipboard
Typed argument parser for Python
Unless I've missed something, the usage of subparsers annihilates the advantages of this library. If I take your example: ```python3 class SubparserA(Tap): bar: int # bar help class Args(Tap): foo:...
I've got a use-case where I need to parse args repeatedly. For now, I am simply doing ```python parser._parsed = False ``` But an official flag in ```__init__``` would be...
Introduced in 1.7.2, when using TAP to parse arguments, arguments with quotes within the argument remove the quote. This was likely introduced when handling quoted arguments. It appears to be...
`ClassVar` is (quoting from [here][ClassVar] in typing docs, emphasis mine): > Special type construct to mark class variables. > > [...] a variable annotation wrapped in `ClassVar` indicates that a...
Currently, parser class and the namespace object are the same type and object. ```python from tap import Tap class SimpleArgumentParser(Tap): name: str language: str = 'Python' args: SimpleArgumentParser = SimpleArgumentParser().parse_args()...
Hi, I'm using sub parsers and I assumed that the `Tap` for the chosen sub parser would be returned from `parse_args()` however the parent parser is actually returned. The motivation...
This looks like a really excellent and much-needed package, thank you! Then I thought: I wonder if it's in Debian? But to my dismay, I discovered that Debian already has...
hello, Could you make it so that options for enums appear in the help-message? here is a code example ```python3 from enum import Enum from typing import Literal from tap...
Is it possible to specify which configuration file to load in an argument? So instead of: ```python class Args(Tap): arg1: int arg2: str args = Args(config_files=['my_config.txt']).parse_args() ``` Something like this:...