From e87bb63c6ff6c7ac4d85f46ab0c4ec5556a7fc9c Mon Sep 17 00:00:00 2001 From: bennykok Date: Sun, 25 Feb 2024 19:16:51 -0800 Subject: [PATCH] fix(plugin): is_realtime check failed causing everything to not upload --- custom_routes.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/custom_routes.py b/custom_routes.py index c090488..8de4d37 100644 --- a/custom_routes.py +++ b/custom_routes.py @@ -552,7 +552,7 @@ async def update_run_live_status(prompt_id, live_status, calculated_progress: fl if prompt_id not in prompt_metadata: return - if prompt_metadata[prompt_id].is_realtime: + if prompt_metadata[prompt_id].is_realtime is True: return print("progress", calculated_progress) @@ -575,8 +575,9 @@ def update_run(prompt_id: str, status: Status): if prompt_id not in prompt_metadata: return + # if prompt_metadata[prompt_id].start_time is None and status == Status.RUNNING: # if its realtime prompt we need to skip that. - if prompt_metadata[prompt_id].is_realtime: + if prompt_metadata[prompt_id].is_realtime is True: return if (prompt_metadata[prompt_id].status != status): @@ -716,7 +717,7 @@ def is_prompt_done(prompt_id: str): Returns: bool: True if the prompt is marked as done, False otherwise. """ - if prompt_id in prompt_metadata and prompt_metadata[prompt_id].done: + if prompt_id in prompt_metadata and prompt_metadata[prompt_id].done is True: return True return False @@ -805,7 +806,7 @@ async def update_run_with_output(prompt_id, data, node_id=None): if prompt_id not in prompt_metadata: return - if prompt_metadata[prompt_id].is_realtime: + if prompt_metadata[prompt_id].is_realtime is True: return status_endpoint = prompt_metadata[prompt_id].status_endpoint