OP-2414 - Hound

This commit is contained in:
Petr Kalis 2022-02-09 12:59:12 +01:00
parent d953507314
commit 755d7a1d95
6 changed files with 13 additions and 14 deletions

View file

@ -3,8 +3,6 @@
Anything that isn't defined here is INTERNAL and unreliable for external use.
"""
from . import plugin
from .pipeline import (
ls,
install,

View file

@ -15,7 +15,6 @@ import signal
import time
from uuid import uuid4
from Qt import QtWidgets, QtCore, QtGui
import queue
import collections
import platform

View file

@ -67,4 +67,4 @@ class Creator(PypeCreatorMixin, avalon.api.Creator):
harmony.imprint(node, self.data)
self.setup_node(node)
return node
return node

View file

@ -3,7 +3,7 @@ import os
import shutil
from .lib import (
ProcessContext,
ProcessContext,
get_local_harmony_path,
zip_and_move,
launch_zip_file
@ -20,7 +20,8 @@ def file_extensions():
def has_unsaved_changes():
if ProcessContext.server:
return ProcessContext.server.send({"function": "scene.isDirty"})["result"]
return ProcessContext.server.send(
{"function": "scene.isDirty"})["result"]
return False

View file

@ -97,8 +97,8 @@ class StdOutBroker:
return self.webserver_client and self._std_available
def _connect_to_tray(self):
""" Connect to Tray webserver to pass console output. """
if not self._std_available: # not content to log
"""Connect to Tray webserver to pass console output. """
if not self._std_available: # not content to log
return
ws = websocket.WebSocket()
webserver_url = os.environ.get("OPENPYPE_WEBSERVER_URL")
@ -120,7 +120,7 @@ class StdOutBroker:
self._send(payload)
def _disconnect_from_tray(self):
""" Send to Tray that host is closing - remove from Services. """
"""Send to Tray that host is closing - remove from Services. """
print("Host {} closing".format(self.host_name))
if not self.webserver_client:
return
@ -136,7 +136,7 @@ class StdOutBroker:
self.webserver_client.close()
def host_connected(self):
""" Send to Tray console that host is ready - icon change. """
"""Send to Tray console that host is ready - icon change. """
log.info("Host {} connected".format(self.host_id))
payload = {
@ -153,7 +153,7 @@ class StdOutBroker:
self.websocket_server.stop_server(restart=True)
def exit(self):
""" Exit whole application. """
"""Exit whole application. """
self._disconnect_from_tray()
if self.websocket_server:
@ -203,7 +203,7 @@ class StdOutBroker:
self._send(payload)
def _send(self, payload):
""" Worker method to send to existing websocket connection."""
"""Worker method to send to existing websocket connection."""
if not self.send_to_tray:
return
@ -234,7 +234,7 @@ class StdOutBroker:
@staticmethod
def color(message):
""" Color message with html tags. """
"""Color message with html tags. """
message = StdOutBroker._multiple_replace(message,
StdOutBroker.sdict)

View file

@ -7,7 +7,8 @@ exclude =
__pycache__,
docs,
*/vendor,
website
website,
openpype/vendor
max-complexity = 30