Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
False positive with E1136 unsubscriptable-object #1498
Comments
rogalski
added
the
control_flow
label
May 31, 2017
erjiang
commented
Jul 7, 2017
|
This has hit us too. We are using a variable that is initialized to None, but then gets assigned to dict in a loop. I think something like this will trigger it too:
not sure how you would solve this, seems like the inferencer would have to go into the if/else clauses to see what might get assigned to the variable to figure out that it's Union(None, dict). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
sam-s commentedMay 24, 2017
Steps to reproduce
z.pypylint z.pyCurrent behavior
Expected behavior
no errors, no warnings
pylint --version output