[Feature] positional-only args are always Arguments, keyword-only args are always Options, normal args are unchanged #593
Unanswered
matthewgdv
asked this question in
Questions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
First Check
Commit to Help
Example Code
Description
typer.Argument
ortyper.Option
are needed aside from the default value are more verbose than they need to be and don't take advantage of python's syntactic sugar for positional-only and keyword-only argumentsWanted Solution
Have typer leave normal arguments the same as they are currently for backwards-compatibility but allow positional-only arguments to always create an
Argument
instance (even if given a default value), while keyword-only arguments would always result in anOption
instance (even without a default value)Wanted Code
Alternatives
No response
Operating System
Windows
Operating System Details
No response
Typer Version
0.3.2
Python Version
Python 3.9.0rc1
Additional Context
No response
Beta Was this translation helpful? Give feedback.
All reactions