Skip to content
Browse files

Ensure that nuke.ask() isn't called to verify the connection if Nuke …

…isn't in GUI mode. Also, when starting a Managed Server, ensure that verifyConnection is always turned off
  • Loading branch information...
1 parent fdbdad9 commit 1b8d102f1a1afbec2290f7686807461a4e25871b @HughMacdonald HughMacdonald committed
Showing with 6 additions and 2 deletions.
  1. +6 −2 nukeExternalControl/server.py
View
8 nukeExternalControl/server.py
@@ -120,7 +120,11 @@ def verify_connection(self, host):
host in ["localhost", os.getenv("HOST")]):
return True
- return nuke.executeInMainThreadWithResult(nuke.ask, ("Something is trying to connect to Nuke from %s.\nDo you wish to allow this?" % host,))
+ # If Nuke isn't running in GUI mode, then allow the connection to verify
+ if nuke.GUI:
+ return nuke.executeInMainThreadWithResult(nuke.ask, ("Something is trying to connect to Nuke from %s.\nDo you wish to allow this?" % host,))
+
+ return True
def get(self, data):
obj = self.get_object(data['id'])
@@ -224,7 +228,7 @@ class NukeManagedServer(NukeInternal):
def __init__(self, port=None, manager_port=None, manager_host='localhost'):
self.manager_port = manager_port
self.manager_host = manager_host
- NukeInternal.__init__(self, port)
+ NukeInternal.__init__(self, port, VERIFY_CONNECTION_NONE)
def start_server(self, socket):
'''

0 comments on commit 1b8d102

Please sign in to comment.
Something went wrong with that request. Please try again.