Webpublisher - backend - hound

This commit is contained in:
Petr Kalis 2021-07-28 18:10:09 +02:00
parent 824714c2f8
commit bfd2ad65cf
4 changed files with 6 additions and 11 deletions

View file

@ -29,8 +29,8 @@ def install():
avalon.on("application.launched", application_launch)
def uninstall():
pyblish.deregister_plugin_path(PUBLISH_PATH)
avalon.deregister_plugin_path(avalon.Loader, LOAD_PATH)
avalon.deregister_plugin_path(avalon.Creator, CREATE_PATH)

View file

@ -169,7 +169,7 @@ class CollectPublishedFiles(pyblish.api.ContextPlugin):
"manifest.json"))
self.log.info("task_data:: {}".format(task_data))
ctx = task_data["context"]
asset = subset = task = task_type = None
task_type = None
subset = "Main" # temp
if ctx["type"] == "task":
@ -289,4 +289,3 @@ class CollectPublishedFiles(pyblish.api.ContextPlugin):
)
self._process_batch(batch_dir)

View file

@ -165,7 +165,7 @@ class WebpublisherPublishEndpoint(_RestApiEndpoint):
print("args:: {}".format(args))
exit_code = subprocess.call(args, shell=True)
_exit_code = subprocess.call(args, shell=True)
return Response(
status=200,
body=self.resource.encode(output),
@ -279,4 +279,3 @@ def run_webserver(*args, **kwargs):
webserver_module.start_server()
while True:
time.sleep(0.5)

View file

@ -191,8 +191,7 @@ class PypeCommands:
"finish_date": datetime.now(),
"status": "error",
"msg": error_format.format(**result)
}
}
}}
)
sys.exit(1)
else:
@ -201,8 +200,7 @@ class PypeCommands:
{"$set":
{
"progress": result["progress"]
}
}
}}
)
dbcon.update_one(
@ -212,8 +210,7 @@ class PypeCommands:
"finish_date": datetime.now(),
"state": "finished_ok",
"progress": 1
}
}
}}
)
log.info("Publish finished.")