Maya 2011 Python scriptNode

2011 is supposed to be able to create scriptNodes w/ Python language inside instead of MEL, w/ the sourceType switch, like:

cmds.scriptNode( n=‘test’, bs=‘cmds.cone()’, stp=‘python’ )

I get errors when I try to test the scriptNode. Seems to still think it is MEL code. Anybody else confirm? or (hopefully) I’m missing something.

Wrapping huge python commands into the ‘python’ call inside MEL scripts inside scriptNodes is painful. Would like to use native python in there.

Thanks,

What sort of error are you getting? I did a basic test with this same command and it works.

Excellent. So the new feature works. That’s more important. Must be something on my end.

The errors I get are the same errors that you get when you paste the python line into the MEL tab in the script editor. i.e.- It still thinks its a Mel scriptNode.

Though, I query the node to see its type:
scriptNode(‘test’,q=1,stp=1)

and it returns ‘python’; hmmm, strange.

So Autodesk got back to me and they said that indeed it does create the scriptNode as type python, it is just that the ‘Test Script’ button in the Expression/ScriptNode editor only executes the code in MEL. (lame). If you run the script via commands, it works fine. i.e.-

scriptNode(‘test’, executeBefore=1)