diff --git a/handler.py b/handler.py index ceaf765..be571e7 100644 --- a/handler.py +++ b/handler.py @@ -456,6 +456,15 @@ def handler(job: dict) -> dict: history = poll_for_completion(prompt_id, timeout) print("Workflow completed") + # Debug: print history structure + print(f"History keys: {history.keys()}") + if "outputs" in history: + print(f"Output nodes: {list(history['outputs'].keys())}") + for node_id, node_out in history["outputs"].items(): + print(f" Node {node_id}: {list(node_out.keys())}") + if "status" in history: + print(f"Status: {history['status']}") + # Get output files outputs = get_output_files(history)