Skip to content

Conversation

michaelosthege
Copy link
Member

This PR inverts the run_mypy.py script from a list of known PASSING to a list of known FAILING source files.

This list is shorter (🥳) and can be read as a TODO-list for which files need attention.

Checklist

Major / Breaking Changes

  • None

Bugfixes / New features

  • None

Docs / Maintenance

  • The run_mypy.py script now uses a list of known failing source files.

@michaelosthege michaelosthege marked this pull request as ready for review December 10, 2022 20:22
@michaelosthege michaelosthege changed the title Switch from pass-listing to fail-listing Switch run_mypy.py from pass-listing to fail-listing Dec 10, 2022
@ricardoV94 ricardoV94 merged commit 6440d59 into pymc-devs:main Dec 12, 2022
@michaelosthege michaelosthege deleted the invert-run-mypy branch December 12, 2022 07:53
@maresb
Copy link
Contributor

maresb commented Dec 12, 2022

I'm very curious: how does the execution time of run_mypy.py differ from that of a single invocation of mypy on the codebase?

The reason I'm asking is that we currently do a for loop, iterating over all the .py files. I suspect that starting and stopping the mypy process carries a lot of overhead. Perhaps there's some better way? It'd be really nice to be able to run mypy in the local pre-commit.

@ricardoV94
Copy link
Member

Do you mind investigating?

@michaelosthege
Copy link
Member Author

There's only one mypy invocation in run_mypy.py. check the subprocess call at the bottom of the script

@maresb
Copy link
Contributor

maresb commented Dec 12, 2022

Ah, yes, thanks @michaelosthege! Sorry, I was confused.

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

Successfully merging this pull request may close these issues.

3 participants