Closed Redlnn closed 3 years ago
描述你遇到的问题: 当接收到 MemberLeaveEventKick 广播的时候会报错
MemberLeaveEventKick
复现步骤: 该 BUG 会在进行以下操作后出现:
GroupMessage
发生错误的代码
(省略了前面import和配置bcc的部分)
@bcc.receiver('MemberLeaveEventKick') async def group_member_leave_kick_handler(group: Group, member: Member, app: GraiaMiraiApplication): await app.sendGroupMessage(group, MessageChain(__root__=[ Plain('123') ]))
控制台日志输出截图:
graia报错(Windows):
Traceback (most recent call last): File "C:\Users\Red_lnn\AppData\Local\Programs\Python\Python39\lib\site-packages\graia\broadcast\__init__.py", line 177, in Executor parameter_compile_result[name] = await dii.lookup_param( File "C:\Users\Red_lnn\AppData\Local\Programs\Python\Python39\lib\site-packages\graia\broadcast\interfaces\dispatcher.py", line 310, in lookup_param raise RequirementCrashed( graia.broadcast.exceptions.RequirementCrashed: ('the dispatching requirement crashed: ', 'member', <class 'graia.application.group.Member'>, None)
graia报错(Debian):
Traceback (most recent call last): File "/home/redlnn/.local/lib/python3.7/site-packages/graia/broadcast/__init__.py", line 178, in Executor name, annotation, default, target.param_paths[name] File "/home/redlnn/.local/lib/python3.7/site-packages/graia/broadcast/interfaces/dispatcher.py", line 314, in lookup_param self.default, graia.broadcast.exceptions.RequirementCrashed: ('the dispatching requirement crashed: ', 'member', <class 'graia.application.group.Member'>, None)
mirai-console中相关的只有下列这一行(QQ号脱敏了):
2021-04-17 23:27:08 V/Bot.10000: Event: MemberLeaveEvent.Kick(member=10086, operator=10010)
运行环境:
mirai-core
mirai-api-http
graia-application-mirai
额外信息:
相关库的版本:
python 3.9 / 3.7 graia-broadcast 0.8.11 aiohttp 3.7.4.post0 chardet 3.0.4 croniter 0.3.37 idna 2.10 regex 2020.11.13 pydantic 1.7 yarl 1.6.3
graia.broadcast.exceptions.RequirementCrashed: ('the dispatching requirement crashed: ', 'member', <class 'graia.application.group.Member'>, None)
发生错误的地方很清楚了, 自己 Ctrl + 左键 进去 MemberLeaveEventKick 类里面看看吧....
描述你遇到的问题: 当接收到
MemberLeaveEventKick
广播的时候会报错复现步骤: 该 BUG 会在进行以下操作后出现:
GroupMessage
替换为MemberLeaveEventKick
接收到广播后发送任意消息发生错误的代码
(省略了前面import和配置bcc的部分)
控制台日志输出截图:
graia报错(Windows):
graia报错(Debian):
mirai-console中相关的只有下列这一行(QQ号脱敏了):
运行环境:
mirai-core
版本: 官方2.6.0mirai-api-http
版本: 1.10.0graia-application-mirai
版本: 0.18.4额外信息:
相关库的版本: