Actually, I don't do any formatting when sending Python code from my IDE (Wing) to Maya. If anyone's interested I have the setup documented here: http://mayamel.tiddlyspot.com/#[[How%20can%20I%20have%20Wing%20send%20Python%20or%20mel%20code%20to%20Maya%3F]] (may have to copy-paste that link) Via that method, I can send both mel and python from the IDE, prettymuch letting me bypass the script editor entirely. But I agree: It's been nice to hear about the various solutions! ;)
On Feb 2, 12:36 am, "Shaun Friedberg" <[email protected]> wrote: > Nice tips everyone! > What I have been doing works fine for sending my Mel or Python scripts to > Maya from my IDE. > I thought it would be nice to remove the need to format my Python using Mel > when sending it to Maya. > > My method is similar to AK Eric. > Thanks again for all the input, definitely gives me some ideas to play with. > > -----Original Message----- > From: [email protected] > > [mailto:[email protected]] On Behalf Of AK Eric > Sent: Tuesday, February 02, 2010 12:18 PM > To: python_inside_maya > Subject: [Maya-Python] Re: commandPort > > Interesting, thanks for the tip, I'll give that a shot. I'm the first > to admit I'm no socket expert ;) > > On Feb 1, 9:41 am, Marc Downie <[email protected]> wrote: > > > As an aside: While you can open a socket with both mel and Python... > > > I've found that no matter what I do, if I open a socket with Python, > > > the above solution won't work.. I have to open it with mel. > > > Frustrating. > > > Well, at least on the mac I can state that this doesn't happen. We open > > sockets (port >1024) from Python all the time and they work like sockets. > > Are you sure you are getting the threadding right for executing the > incoming > > python ? It seems to me that you have to use > executeInMainThreadWithResult() > > [1] in order to have a socket server actually run code that it recieves. > > > Marc > > [1]http://download.autodesk.com/us/maya/2009help/index.html?url=Python_P... > > --http://groups.google.com/group/python_inside_maya > > -- http://groups.google.com/group/python_inside_maya
