GraiaProject / Application

一个设计精巧, 协议实现完备的, 基于 mirai-api-http 的即时聊天软件自动化框架.
https://graia-document.vercel.app/
GNU Affero General Public License v3.0
438 stars 63 forks source link

群员被踢事件好像无法捕获 #2

Closed lindongbin closed 4 years ago

lindongbin commented 4 years ago

代码 @bcc.receiver("MemberLeaveEventKick") async def member_leavekick(app: GraiaMiraiApplication, member: Member): print(member.id)

是不是写错了?日志也没有任何反应,事件换成退群的可以正常运行

另外想问下如何@群成员

代码 await app.sendGroupMessage(group, MessageChain.create([At(member.id), Plain("测试")]))

提示错误 File "pydantic/main.py", line 334, in pydantic.main.BaseModel.init TypeError: init() takes exactly 1 positional argument (2 given)

GreyElaina commented 4 years ago