And it worked great I could type, “import maya.cmds as cmds” then type “cmds.” and hit autocomplete and I’d be presented with a nice list of functions to autocomplete to.
However it stopped working after I restarted eclipse.
I have run into one time where Eclipse auto complete stopped working (but it’s been months now). Right click on your pyDev project in the package explorer and go to properties->PyDev-PYTHONPATH->Source Folders tab. Click the Force Restore Internal Info button on the lower left.
Another way that also seems to work is to go to Window->Preferences->Interpreter-Python->Libraries tab. Select the python interpreter that you want to fix in the list of Python interpreters. Click Apply on the lower right.
Hope that helps.
PS. I will update my write up with a trouble shooting section when I get the time. When you do have this set up it actually is fairly major. When setting up Python super classes and classes that extend’s it’s methods you just have to mouse over references to any methods and a window will pop up to the doc tag of that method and which class it is within. There are so many advantages to this set up. It points out unused variables, imports, selecting a variable, method, class highlights it everywhere in your script, pressing F3 with any method selected, finds the module from where it is called and opens it up and goes to the method. Auto complete of Python, Pymel, PyQt with mouse hover pop ups to the doc tags of all those etc, etc, etc
And it worked great I could type, “import maya.cmds as cmds” then type “cmds.” and hit autocomplete and I’d be presented with a nice list of functions to autocomplete to.
However it stopped working after I restarted eclipse.
Its nothing major, just makes life easier.
Cheers.[/QUOTE]
Updated Eclipse IDE Set Up with trouble shooting when autocomplete stops working, as well as getting real time debugging going…
File “C:\Program Files\eclipse\plugins\org.python.pydev.debug_1.6.5.2011020317\pysrc\pydevd.py”, line 1015, in _locked_settrace
debugger.connect(host, port)
File “C:\Program Files\eclipse\plugins\org.python.pydev.debug_1.6.5.2011020317\pysrc\pydevd.py”, line 286, in connect
s = StartClient(host, port)
File “C:\Program Files\eclipse\plugins\org.python.pydev.debug_1.6.5.2011020317\pysrc\pydevd_comm.py”, line 347, in StartClient
sys.exit(1)
SystemExit: 1
It seems it was trying to connect through a different port? Eh???
But the second time I run it there’s no error. Even though I had started the debugger in Eclipse, I don’t see any breakpoints being hit, or any evidence at all that there’s a connection between maya and Eclipse.
I’ve been revisiting my Eclipse Maya Editor plugin. As has been commented in the past, the way I found to implement the connection to/from Maya leads to higher machine resources. I was using Eclipse’s internal Job API which I thought was the preferred method. I just switched over to using a normal Java thread and I now have almost no machine resources being used. Yay!
Most other IDE’s that allow communication with Maya only deal with sending commands TO Maya. They don’t allow capturing Maya’s return statements back FROM Maya. My plugin does and puts it in a console view. No syntax highlighting in consoles, though. It needs to be put in an editor view instead for highlighting. But when I tried this, I always got an annoying pop up window asking to accept file changes. I couldn’t find a way to turn this off - until now. The editor has to be part of an existing project in order to turn it off. So I’ll be modifying the plugin to take advantage of this. Soon.
Hey cgjedi, just wanted to say thanks for the updated Eclipse>Maya bridge. Fixed a few minor bugsI was having, and I get the correct line numbers with errors.