From 08099d7067fce5814063aa6478abcb9b167b6d49 Mon Sep 17 00:00:00 2001 From: Krzysztof Rudnicki Date: Mon, 24 Jun 2024 19:34:53 +0200 Subject: [PATCH] feat: show error tpye when trigger command fails --- main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index bdb12b3..8835dd1 100644 --- a/main.py +++ b/main.py @@ -155,8 +155,10 @@ async def trigger_command(message_content, recipient): if message_value in command_triggers: await command_function(recipient) break + except TypeError: + send_message(f"trigger_command, TypeError {message_content}", recipient) except: - send_message("Rudnik coś popsuł", recipient) + send_message(f"trigger_command, unknown error {message_content}", recipient) async def send_to_group(message_content): if message_group_id(message_content) == GROUP_ID: