PyCharm: "unresolved reference" for "object", "isinstance", etc.

I am using PyCharm with python 2.7

PyCharm shows an "Unresolved reference" for things I believe are keywords or part of the Python language. For example:

class MyClass(object):


PyCharm states that "object" is an "unresolved reference" displaying an error sign. Similarely, "isinstance" and many other built-in methods don't seem to be resolved.

It looks like the problem is with the definition of the Python interpreter. To be able to send an IML file (where the path to the interpreter is stored), I created my own python interpreter named "MyPython" and set it to point to the interpreter on the machine. This interpreter does not have a path in the name (as it differs between machines) and it is not the one automatically generated by PyCharm. I only see this behavior when I am on MyPython. When on the generated PyCharm, that is: "Parsing Python 2.7.8 (C: \ Python27 \ python.exe)" is fine. Looks like a bug in PyCharm?


source to share

All Articles