Getting PyCharm to see Maya and PySide2 API

by tigerSoda posted 339 days ago | 2 comments


I'm using PyCharm as my text editor. How can I get it to recognize Maya commands (Maya.cmds, pymel, pyside2, etc)?


by theoldhunter posted 333 days ago

I am sure there you will find some articles on the internet with specific instructions but here are some quick directions. Let me know if you have any issues:

Once you open your project, you will have to add the mayapy as a Project Interpreter in settings:

Settings>Project:{YOUR PROJECT}>Project Interpreter>Add>System Interpreter

Point it to mayapy (.exe if on windows) in your Autodesk Maya version directory.

After adding the interpreter, you have to add this path to "Interpreter Paths" (This is a part of Maya devkit):

devkit/other/pymel/extras/completion/py (An alternative way is to just add this path to your system python2 interpreter, that should work too).

And Remove this path: mayaXXXX/lib/python2.7/site-packages (This is on Linux but it should be something similar on Windows)

Now you should have code completion for Maya cmds and pymel.

Note: Since PyCharm is an IDE, I use it for projects only. For single files, I use vscode as a text editor.

by tigerSoda posted 319 days ago

Hi @theoldhunter, thanks for the tip, it worked!

Autodesk/maya2020/devkit was empty, so I downloaded the Maya 2020 devkit from their site, copied the contents inside the devkit folder to the empty one.

I remember QtDesigner coming with Maya, and I was able to access it in Maya 2018 (Windows). Where did it go in Maya 2020 (Mac)?