Make it possible to use `modules` or `packages` configurations with `files`
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 20.6k
- Forks
- 3.3k
- PR merge metrics
- PR metrics pending
Description
Feature
Make it possible to use modules or packages configurations with files.
Pitch
Currently, when using modules or packages configurations with files, we get the following error:
usage: mypy [-h] [-v] [-V] [more options; see below]
[-m MODULE] [-p PACKAGE] [-c PROGRAM_TEXT] [files ...]
mypy: error: May only specify one of: module/package, files, or command.
I did not see any mention of such restriction in the documentation.
Nevertheless, it could be useful to check in a single mypy execution:
- the core packages with
modulesorpackages, which configurations seem to handle correctly pkgutil-style namespace packages (see #9393), - other standalone scripts (tools, tests, ...) with
files.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the mypy command-line validation that emits the mutually exclusive module/package, files, or command error, then compare it with the modules, packages, and files configuration documentation. Done means one invocation can check configured modules or packages together with standalone files, with coverage for the existing namespace-package behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, devtools
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100