debug: Add callback chain debugging to InferencePipeline and WorkflowOrchestrator

- Add debug output in InferencePipeline result callback to see if it's called
- Add debug output in WorkflowOrchestrator handle_result to trace callback flow
- This will help identify exactly where the callback chain is breaking
- Previous test showed GUI can receive signals but callbacks aren't triggered
This commit is contained in:
Masonmason 2025-07-23 22:43:06 +08:00
parent dc36f1436b
commit 2dec66edad
2 changed files with 6 additions and 0 deletions

View File

@ -485,7 +485,10 @@ class InferencePipeline:
# Call result callback # Call result callback
if self.result_callback: if self.result_callback:
print(f"🔍 PIPELINE DEBUG: Calling result_callback with: {current_data}")
self.result_callback(current_data) self.result_callback(current_data)
else:
print(f"🔍 PIPELINE DEBUG: No result_callback set!")
except queue.Full: except queue.Full:
# Drop oldest and add new # Drop oldest and add new

View File

@ -159,6 +159,9 @@ class WorkflowOrchestrator:
""" """
Callback function to handle results from the pipeline. Callback function to handle results from the pipeline.
""" """
print(f"🔍 ORCHESTRATOR DEBUG: handle_result called with: {result_data}")
print(f"🔍 ORCHESTRATOR DEBUG: result_callback is: {self.result_callback}")
if self.result_handler: if self.result_handler:
try: try:
# Convert PipelineData to a dictionary for serialization # Convert PipelineData to a dictionary for serialization