Hi,
try something like this, it´s weird but it works.
def onKnobChangedCallback():
def threadedProcess( node , first , last ):
nuke.executeInMainThreadWithResult( nuke.execute , args = ( node , first ,
last ) , kwargs = { 'continueOnError' : True } )
if nuke.thisKnob().name() == 'MyButton':
import threading
thread = threading.Thread( None , threadedProcess , args = ( < WRITE NODE >
, < FIRST FRAME > , < LAST FRAME > ) )
nuke.executeInMainThread( thread.start )
hope it helps.
J
2011/9/13 mrrafs <[email protected]>
> **
> has anyone got an answer to this? i.e.
>
> I have a non-modal panel with a self.knobChanged(knob) that exec's a
> function with a nuke.execute() in it. and then i get a: 'RuntimeError: I'm
> already executing something else '.
>
> Running the function from menu/script editor is ok.
>
> i have tried:
> - utils.executeInMainThread(): no error but the progress bar is frozen
> - threading.Thread(): error & the progress bar is frozen
> - nuke.executeInMainThreadWithResult(): error & the progress bar is frozen
>
> _______________________________________________
> Nuke-python mailing list
> [email protected], http://forums.thefoundry.co.uk/
> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
>
>
_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python