From 8cf055521c3934b1de248c6151987b07ba31b582 Mon Sep 17 00:00:00 2001 From: yym68686 Date: Mon, 7 Oct 2024 21:28:49 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Bug:=20Fix=20the=20bug=20where?= =?UTF-8?q?=20channel=20responses=20fail=20but=20are=20replied=20to=20norm?= =?UTF-8?q?ally=20and=20are=20not=20recognized=20as=20a=20request=20failur?= =?UTF-8?q?e.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/utils.py b/utils.py index 14b46ee..620cbec 100644 --- a/utils.py +++ b/utils.py @@ -133,7 +133,10 @@ async def error_handling_wrapper(generator): logger.error("error_handling_wrapper [DONE]!") raise StopAsyncIteration if "The bot's usage is covered by the developer" in first_item_str: - logger.error("error const string!") + logger.error("error const string: %s", first_item_str) + raise StopAsyncIteration + if "process this request due to overload or policy" in first_item_str: + logger.error("error const string: %s", first_item_str) raise StopAsyncIteration try: first_item_str = json.loads(first_item_str)