-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Pylint does not report "unused-import" if there are quotes around type hint #7679
Comments
Thanks for the report @hofrob. Unfortunately I can't reproduce it the way you've described ( However I do see the behaviour when linting individual modules: |
Thanks! I will take a look later if it fixes what I'm seeing.
This kind of situation is happening a lot recently. I had a docker container where pylint did not show any messages in our CI, but running the exact same container locally showed the correct messages. I'm running into this a lot at work with co-workers executing pylint with different results. Often times the order of paths in the command line changes the outcome, but it's not the same on all machines (even if they use the same docker container). Is there any issue regarding this? Do other people report something similar? I couldn't find any threads because I don't even know what to look for to be honest. |
Yes, there's an issue with multiprocessing and parallelization the hashmap is not implemented on all checkers (#374). Do not use multiprocessing, the increase in performance is negligible anyway (#2525 : the work in astroid to fix this is humongous). There's also a problem with the order of file given (#689 and #4053) |
Can confirm! All false negatives are fixed now. Thanks for the helpful feedback! |
Bug description
I used
hatch
to create this example repo (pipx install hatch
).hatch run pylint -d all -e W0611 test_pylint/ tests/
test_pylint/baz.py
test_pylint.foo.foo_baz
function (aroundbar.SomeClass
)hatch run pylint -d all -e W0611 test_pylint/ tests/
Those two things should be unrelated I'd say. No idea why quotes (even if they don't make sense) influence an unused import warning in a completely unrelated file.
Configuration
No response
Command used
Pylint output
Expected behavior
Pylint version
OS / Environment
Hatch, version 1.5.0
Additional dependencies
No response
The text was updated successfully, but these errors were encountered: