Skip to content

Option to recurse into namespace packages #7380

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

Closed
Jackenmen opened this issue Aug 22, 2019 · 2 comments
Closed

Option to recurse into namespace packages #7380

Jackenmen opened this issue Aug 22, 2019 · 2 comments

Comments

@Jackenmen
Copy link

Jackenmen commented Aug 22, 2019

Unless current behaviour is unintended, this is more of a feature request.

I would like to have option for mypy to recurse into namespace packages - currently if I have somepackage with ext namespace package, mypy will not recurse into packages in that namespace package. Here's an example tree:

.
└── somepackage
    ├── __init__.py
    ├── module_a.py
    └── ext
        └── someextension
            ├── __init__.py
            └── module_b.py

For such tree, running mypy --strict --namespace-packages -p somepackage will only check files that are inside somepackage. Adding empty __init__.pyi to ext folder will solve this problem but it's really just a workaround for this problem.

I checked this tree with mypy from master (Python 3.7.4) to make sure this wasn't solved in the meantime.

@ilevkivskyi
Copy link
Member

Just double-check is this a duplicate of #6385 or you want something different?

@Jackenmen
Copy link
Author

Yes, looks like it, my bad, I rushed with sending this issue a little and only looked through most recent issues regarding namespace packages.

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

No branches or pull requests

2 participants