Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh-101472: Add nargs='...' to the reference of add_argument in argparse #101473

Closed
wants to merge 1 commit into from

Conversation

ppaez
Copy link
Contributor

@ppaez ppaez commented Jan 31, 2023

This provides a fix to improve the documentation.

@hpaulj
Copy link

hpaulj commented Apr 18, 2023

This patch conflicts with a more recent one, #103582

argparse.REMAINDER is ...

We can't both remove all references to REMAINDER and add it's literal value back in.

Subparsers use 'argparse.PARSERwhich is 'A...'. It's a validnargsvalue, but only used by the_SubParsersActionclass. Not all possiblenargs` values have to be documented.

@hauntsaninja
Copy link
Contributor

hauntsaninja commented Apr 19, 2023

Thanks for the PR, and thanks hpaulj for linking to the other PR.

However, I left a comment on #101472 (comment) mentioning what I think the ways forward for this are.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting review docs Documentation in the Doc dir skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants