Is it possible to disable an inspection for the whole file in PyCharm?
The reason this is needed is when dealing with py.test. It uses fixtures which appear to shadow function parameters, and at the same time cause unresolved references. e.g.:
from myfixtures import user # Unused import statement warning
def test_is_awesome(user): # Shadows name 'user' from outer scope warning
assert user.is_awesome()
There is also other warnings from py.test, such as using pytest.raises()
causes a "Can not find reference 'raises'" in pytest.py.
Maybe there's another way to fix these problems? Maybe I'm using py.test incorrectly?