Can I make the pycharm inspector being able to find errors of "undefined class instance variable"?
Answered
Can I make the pycharm inspector being able to find an error of "undefined class instance variable"?
For example:
def class c:
def method1():
a = 2 * self.b
If the variable b in method1 is not defined in any place nor any method of class c, this should be one usage of a class instance variable that is not defined. I want the inspector to highlight an error in such a case. Can this be done?
Please sign in to leave a comment.
Hi,
If I correctly understand your use-case and properly use your code snippet, you would like to see the following warning, right?
Don't you have it?