perf: 完善报错堆栈显示
This commit is contained in:
@@ -32,6 +32,7 @@ from util.cmd_config import CmdConfig as cc
|
||||
import util.gplugin as gplugin
|
||||
from PIL import Image as PILImage
|
||||
import io
|
||||
import traceback
|
||||
|
||||
|
||||
|
||||
@@ -665,6 +666,7 @@ def oper_msg(message,
|
||||
if chosen_provider in reply_prefix:
|
||||
chatgpt_res = reply_prefix[chosen_provider] + chatgpt_res
|
||||
except BaseException as e:
|
||||
gu.log(f"调用异常:{traceback.format_exc()}", gu.LEVEL_ERROR)
|
||||
gu.log("调用语言模型例程时出现异常。原因: "+str(e), gu.LEVEL_ERROR)
|
||||
send_message(platform, message, "调用语言模型例程时出现异常。原因: "+str(e), msg_ref=msg_ref, session_id=session_id)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user