Skip to content

Recategorize and document --warn-incomplete-stub #5555

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

Merged

Conversation

Michael0x2a
Copy link
Collaborator

Previously, the --warn-incomplete-stub flag was inconsistently documented: it was missing from the "Mypy command line" section of the docs, but was documented in the "Mypy configuration file" section and appeared under "Untyped definitions and calls" section when running mypy --help.

This pull request:

  1. Adds documentation for this flag to the command line docs.

  2. Recategorizes the flag to fall under "Mypy internals" -- I can't really see people other then typeshed contributors finding this flag useful.

  3. Updates the docs so it states this flag is useful only when using --disallow-incomplete-defs or --disallow-untyped-defs instead of --check-untyped-defs. This option appears to be used only once in checker.py -- the check_untyped_defs option does not seem relevant there.

Previously, the `--warn-incomplete-stub` flag was inconsistently
documented: it was missing from the "Mypy command line" section of
the docs, but was documented in the "Mypy configuration file" section
and appeared under "Untyped definitions and calls" section when
running `mypy --help`.

This pull request:

1.  Adds documentation for this flag to the command line docs.

2.  Recategorizes the flag to fall under "Mypy internals" -- I
    can't really see people other then typeshed contributors
    finding this flag useful.

3.  Updates the docs so it states this flag is useful only when
    using `--disallow-incomplete-defs` or `--disallow-untyped-defs`
    instead of `--check-untyped-defs`. This option appears to be
    used [only once in checker.py][0] -- the `check_untyped_defs`
    option does not seem relevant there.

  [0]: https://github.com/python/mypy/blob/master/mypy/checker.py#L947
@Michael0x2a Michael0x2a force-pushed the adjust-warn-incomplete-stub-docs branch from 9fa99ed to 9ddffa7 Compare September 1, 2018 19:43
@gvanrossum gvanrossum merged commit 581e514 into python:master Sep 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants