logging adjusted
This commit is contained in:
@ -35,8 +35,8 @@ def process_message(box_name, topic_key, payload, context):
|
||||
try:
|
||||
box = context['boxes'][box_name]
|
||||
local_context = box['context']
|
||||
logger.info(f"Local context before: {local_context}")
|
||||
logger.info(f"[{box_name}, {box['label']}] Processing message for '{topic_key}': {payload}")
|
||||
logger.info(f"[{box_name}] Local context before: {local_context}")
|
||||
logger.info(f"[{box_name}] Processing message for '{topic_key}': {payload}")
|
||||
|
||||
match topic_key.split('/'):
|
||||
case [ primary_key, sub_key ] if primary_key == 'window':
|
||||
@ -60,7 +60,7 @@ def process_message(box_name, topic_key, payload, context):
|
||||
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}")
|
||||
logger.info(f"[{box_name}] 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