You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but with that code mypy emits the following error:
541: error: Argument "formatter_class" to "ArgumentParser" has incompatible type "Callable[[Any], RawDescriptionHelpFormatter]"; expected "Type[HelpFormatter]"
I could not find any workaround, the only solution is to avoid a function and redefine the formatter class.
I'm reopening here the issue originally opened for mypy, see reply.
I'm using mypy 0.761 with Python 3.8.2 on Windows.
The suggested way to customize the argparse formatter class to control text width is to use a lambda function, as follows:
but with that code mypy emits the following error:
I could not find any workaround, the only solution is to avoid a function and redefine the formatter class.
See example and discussion.
The text was updated successfully, but these errors were encountered: