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

stubtest: add error summary, other output nits #12855

Merged
merged 5 commits into from May 28, 2022

Conversation

KotlinIsland
Copy link
Contributor

@KotlinIsland KotlinIsland commented May 23, 2022

  • error summary
  • fix issue where module is presented as a stub
  • handle loading modules that output or raise BaseException
  • output formatted messages instead of tracebacks
  • add some more tests

Also:

  • move plural_s from messages to util
  • use plural_s in summary functions

Test Plan

I added some tests

resolves #12547

- error summary
- fix issue where module is saved as stub
- handle loading modules that output or raise
- output messages instead of tracebacks
- add some more tests

Also:
- move plural_s from messages to util
- use plural_s in summary functions
@github-actions

This comment has been minimized.

Copy link
Collaborator

@hauntsaninja hauntsaninja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I fixed some bugs this introduced related to allowlists and simplified some functionality I don't think is needed. The change to only look at pyi files is good, but should be its own PR (I copied the changes over to #12889). In general, it's good practice to separate behaviour changes like that from cosmetic changes.

@hauntsaninja hauntsaninja changed the title stubtest improvements stubtest: add error summary, other output nits May 28, 2022
@github-actions

This comment has been minimized.

2 similar comments
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

mypy/stubtest.py Show resolved Hide resolved
mypy/stubtest.py Show resolved Hide resolved
@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@hauntsaninja hauntsaninja merged commit e661890 into python:master May 28, 2022
16 checks passed
@KotlinIsland KotlinIsland deleted the fix_stubtest branch July 20, 2022 13:45
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.

(🎁) stubtest should show an error summary
2 participants