We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dfdc5c0 commit bc11209Copy full SHA for bc11209
1 file changed
pep8.py
@@ -967,10 +967,8 @@ def python_3000_has_key(logical_line, noqa):
967
Okay: if "alph" in d:\n print d["alph"]
968
W601: assert d.has_key('alph')
969
"""
970
- if noqa:
971
- return
972
pos = logical_line.find('.has_key(')
973
- if pos > -1:
+ if pos > -1 and not noqa:
974
yield pos, "W601 .has_key() is deprecated, use 'in'"
975
976
0 commit comments