more logging output
This commit is contained in:
@ -35,7 +35,7 @@ def process_message(box_name, topic_key, payload, context):
|
||||
try:
|
||||
box = context['boxes'][box_name]
|
||||
local_context = box['context']
|
||||
logger.info(f"{local_context=}")
|
||||
logger.info(f"Local context before: {local_context}")
|
||||
logger.info(f"[{box_name}, {box['label']}] Processing message for '{topic_key}': {payload}")
|
||||
|
||||
match topic_key.split('/'):
|
||||
@ -59,6 +59,8 @@ def process_message(box_name, topic_key, payload, context):
|
||||
publish_topic = box["output_topic"] if not status else context['status_topic']
|
||||
context['client'].publish(publish_topic, result_message)
|
||||
logger.info(f"[{box_name}] Result published on '{publish_topic}': {status} {result_message}")
|
||||
|
||||
logger.info(f"Local context after: {local_context}")
|
||||
except Exception as e:
|
||||
logger.error(f"[{box_name}] Error processing '{topic_key}': {e}")
|
||||
|
||||
|
Reference in New Issue
Block a user