Do not append namespace packages to sys.path#6405
Do not append namespace packages to sys.path#6405Pierre-Sassoulas merged 10 commits intopylint-dev:mainfrom
Conversation
Pull Request Test Coverage Report for Build 2250284307
💛 - Coveralls |
|
I think both approach are not mutually exclusive, the option is a permanent fix to let the user tell pylint what to do. But we can still make namespace automated detection better so users don't have to use the option as often. |
I think we should try to avoid adding the option. There is no inherent reason why we wouldn't be able to mimic the import mechanics of |
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
Pierre-Sassoulas
left a comment
There was a problem hiding this comment.
The change look nice but this is a tricky to tests and easy to break. I'm not super confident. Probably a good thing that we release the beta first here.
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
for more information, see https://pre-commit.ci
jacobtylerwalls
left a comment
There was a problem hiding this comment.
Thanks for the updates, looks great and fails on main!
Pierre-Sassoulas
left a comment
There was a problem hiding this comment.
The test is clever ! Do we release the beta right now or should we first release the current patch versions of astroid and pylint ?
I think we can release the beta. I don't know of any blockers in |
This reverts commit 603be84.
doc/whatsnew/<current release.rst>.and preferred name in
script/.contributors_aliases.jsonType of Changes
Description
Counter to #5235.
This is not finished yet as for some reason running
pylintin pre-commit does not allow this fix. However, I think we should explore if this is a possible solution to the problem. There should be a way to determine whether something is a namespace package, thepythonimport statement can do so as well.Closes #5226, Closes #2648