Skip to content

Suggestion for argparse: raise a warning on type=bool #126676

Description

@user202729

Feature or enhancement

Proposal:

There has been complaints about type=bool usage in argparse: #81745 #83348 #71181 . See also https://stackoverflow.com/questions/15008758/parsing-boolean-values-with-argparse

while we may not want to actually change the behavior (given existing code on the wild might use it, as mentioned in previous discussions), what about raise a warning? Or is that also too intrusive?

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Linked PRs

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc direasystdlibStandard Library Python modules in the Lib/ directory

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions