mirror of
https://github.com/RockChinQ/QChatGPT.git
synced 2024-11-16 03:32:33 +08:00
fix: 插件加载bug
This commit is contained in:
parent
a8b1e6ce91
commit
71b8bf13e4
|
@ -70,6 +70,8 @@ def generate_plugin_order():
|
|||
def iter_plugins():
|
||||
"""按照顺序迭代插件"""
|
||||
for plugin_name in __plugins_order__:
|
||||
if plugin_name not in __plugins__:
|
||||
continue
|
||||
yield __plugins__[plugin_name]
|
||||
|
||||
|
||||
|
|
|
@ -185,7 +185,11 @@ class NakuruProjectAdapter(MessageSourceAdapter):
|
|||
if resp.status_code == 403:
|
||||
logging.error("go-cqhttp拒绝访问,请检查config.py中nakuru_config的token是否与go-cqhttp设置的access-token匹配")
|
||||
raise Exception("go-cqhttp拒绝访问,请检查config.py中nakuru_config的token是否与go-cqhttp设置的access-token匹配")
|
||||
self.bot_account_id = int(resp.json()['data']['user_id'])
|
||||
try:
|
||||
self.bot_account_id = int(resp.json()['data']['user_id'])
|
||||
except Exception as e:
|
||||
logging.error("获取go-cqhttp账号信息失败: {}, 请检查是否已启动go-cqhttp并配置正确".format(e))
|
||||
raise Exception("获取go-cqhttp账号信息失败: {}, 请检查是否已启动go-cqhttp并配置正确".format(e))
|
||||
|
||||
def send_message(
|
||||
self,
|
||||
|
|
Loading…
Reference in New Issue
Block a user