KEMBAR78
Document per-module follow_imports more explicitly by hauntsaninja · Pull Request #10845 · python/mypy · GitHub
Skip to content

Conversation

hauntsaninja
Copy link
Collaborator

@hauntsaninja hauntsaninja commented Jul 21, 2021

Helps with #10842, #10820 and others

There have been a number of issues recently where having this spelt out
a little more explicitly would help users. The introduction of
--exclude also (pretty understandably) confuses users who don't realise
mypy's recursive file discovery is a little separate from its dogged
import following.

I think it could be reasonable to change mypy's behaviour so that
exclude also implies follow_imports=skip (or maybe silent), but it might
be a little finnicky (one is a regex on filenames, the other is patterns
on fully qualified module names). I'm also just wary of attempting to
change this - import following configuration is probably one of the
more complicated and poorly understood parts of mypy's UX - so passing
on that for now.

Helps with python#10842, python#10820 and others

There have been a number of issues recently where having this spelt out
a little more explicitly would help users. The introduction of
`--exclude` also (pretty understandably) confuses users who don't realise
mypy's recursive file discovery is a little separate from its dogged
import following.

I think it could be reasonable to change mypy's behaviour so that
exclude also implies follow_imports=skip (or maybe silent), but it might
be a little finnicky (one is a regex on filenames, the other is patterns
on fully qualified module names). I'm also just wary of attempting to
change this - import following configuration is probably one of the
more complicated and poorly understood parts of mypy's UX - so passing
on that for now.
@hauntsaninja hauntsaninja merged commit 7b0df28 into python:master Aug 1, 2021
@hauntsaninja hauntsaninja deleted the follow branch August 1, 2021 23:14
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.

1 participant