Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

机器人启动后第二次被拉入群聊不会刷新group列表,且不会监听到消息 #580

Closed
XSana opened this issue Sep 8, 2020 · 4 comments
Labels
t:bug 类型: bug x:protocol 属性: 协议相关 z:duplicate 状态: 重复

Comments

@XSana
Copy link

XSana commented Sep 8, 2020

机器人启动后第一次被拉入群聊会报错,但功能正常,之后被拉入群聊Group列表均不会自动刷新,且不会触发监听,控制台仅有 net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify 输出,日志为复现操作所产生的所有日志

2020-09-08 18:02:05 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@52116948
2020-09-08 18:02:05 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:02:05 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@4c4d9c19
2020-09-08 18:02:05 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:02:05 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:02:05 V/Net 1697741994: Send: friendlist.GetTroopListReqV2
2020-09-08 18:02:05 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:02:05 V/Net 1697741994: Send: ProfileService.Pb.ReqSystemMsgNew.Group
2020-09-08 18:02:06 V/Net 1697741994: Recv: FriendList.GetFriendGroupList.Response
2020-09-08 18:02:06 V/Net 1697741994: Send: OidbSvc.0x88d_7
2020-09-08 18:02:06 V/Net 1697741994: Send: friendlist.GetTroopMemberListReq
2020-09-08 18:02:06 V/Net 1697741994: Recv: FriendList.GetTroopMemberList.Response
2020-09-08 18:02:06 E/Net 1697741994: Exception in NetworkHandler
java.util.NoSuchElementException: member -1398657022 not found in group 3946986162
	at net.mamoe.mirai.qqandroid.contact.GroupImpl.get(GroupImpl.kt:277)
	at net.mamoe.mirai.qqandroid.network.protocol.packet.chat.receive.MessageSvcPbGetMsg$decode$$inlined$mapNotNull$1$2.emit(Collect.kt:164)
	at net.mamoe.mirai.qqandroid.network.protocol.packet.chat.receive.MessageSvcPbGetMsg$decode$$inlined$mapNotNull$1$2$1.invokeSuspend(Unknown Source)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.internal.ScopeCoroutine.afterResume(Scopes.kt:32)
	at kotlinx.coroutines.AbstractCoroutine.resumeWith(AbstractCoroutine.kt:113)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:56)
	at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:738)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

2020-09-08 18:02:06 D/Net 1697741994: unknown group 732 type 20, data: 90 08 14 20 B2 9C F4 D9 01 68 13 D2 01 82 01 08 02 10 84 08 18 07 30 C2 08 42 70 3C 67 74 69 70 20 61 6C 69 67 6E 3D 22 63 65 6E 74 65 72 22 3E 20 3C 6E 6F 72 20 74 78 74 3D 22 E4 BD A0 E4 B8 8E E7 BE A4 E9 87 8C E5 85 B6 E4 BB 96 E4 BA BA E9 83 BD E4 B8 8D E6 98 AF E5 A5 BD E5 8F 8B E5 85 B3 E7 B3 BB EF BC 8C E8 AF B7 E6 B3 A8 E6 84 8F E9 9A 90 E7 A7 81 E5 AE 89 E5 85 A8 E3 80 82 22 2F 3E 20 3C 2F 67 74 69 70 3E 50 94 8B FD A8 05
2020-09-08 18:02:06 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:02:14 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:02:39 V/Bot 1697741994: [测试群1(456986162)] 小楠(2896310274) -> [mirai:source:234079,691820221]test
2020-09-08 18:02:40 V/Net 1697741994: Send: MessageSvc.PbSendMsg
2020-09-08 18:02:40 V/Net 1697741994: Recv: MessageSvcPbSendMsg.Response.SUCCESS
2020-09-08 18:02:40 V/Bot 1697741994: Group(456986162) <- 测试回复
2020-09-08 18:02:40 V/Net 1697741994: Send: MessageSvc.PbSendMsg
2020-09-08 18:02:40 V/Net 1697741994: Recv: MessageSvcPbSendMsg.Response.SUCCESS
2020-09-08 18:02:40 V/Bot 1697741994: Group(456986162) <- 测试回复
2020-09-08 18:02:40 V/Net 1697741994: Send: MessageSvc.PbSendMsg
2020-09-08 18:02:40 V/Net 1697741994: Recv: MessageSvcPbSendMsg.Response.SUCCESS
2020-09-08 18:02:40 V/Bot 1697741994: Group(456986162) <- 测试回复
2020-09-08 18:02:40 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:02:40 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:02:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:02:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:02:49 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:02:49 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:03:30 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@d4fb0b5
2020-09-08 18:03:30 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:03:30 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@1b21825e
2020-09-08 18:03:30 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:03:30 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:03:30 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:03:31 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:03:39 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:03:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:03:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:04:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:04:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:05:03 V/Bot 1697741994: [测试群1(456986162)] 小楠(2896310274) -> [mirai:source:234083,585039111]exit
2020-09-08 18:05:03 V/Net 1697741994: Send: ProfileService.GroupMngReq
2020-09-08 18:05:03 V/Net 1697741994: Recv: GroupMngReqResponse(errorCode=0, errorMessage=)
2020-09-08 18:05:03 I/Bot 1697741994: 机器人主动退出一个群
2020-09-08 18:05:03 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:05:12 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:05:31 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@52e99ac0
2020-09-08 18:05:31 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:05:31 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@10206a84
2020-09-08 18:05:31 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:05:31 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:05:31 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:05:32 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:05:40 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:05:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:05:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:06:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:06:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:07:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:07:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:08:34 V/Bot 1697741994: Event: BotLeaveEvent.Active(group=953440223)
2020-09-08 18:08:34 I/Bot 1697741994: 机器人主动退出一个群
2020-09-08 18:08:34 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:08:34 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:08:42 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:08:42 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:08:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:08:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response
2020-09-08 18:08:44 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@5c2e6eed
2020-09-08 18:08:44 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:08:44 V/Net 1697741994: Recv: net.mamoe.mirai.qqandroid.network.protocol.data.jce.RequestPushNotify@1c12e88d
2020-09-08 18:08:44 V/Net 1697741994: Send: MessageSvc.PbGetMsg
2020-09-08 18:08:44 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:08:44 V/Net 1697741994: Send: MessageSvc.PbDeleteMsg
2020-09-08 18:08:45 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:08:53 V/Net 1697741994: Send: OnlinePush.RespPush
2020-09-08 18:09:43 V/Net 1697741994: Send: Heartbeat.Alive
2020-09-08 18:09:43 V/Net 1697741994: Recv: Heartbeat.Alive.Response

复现

  1. 机器人启动后第一次拉入群聊(或新建群聊),会报member -xxxxxx not found in group xxxxxx错误,但监听正常,群列表正常,发送test回复正常
  2. 机器人启动后被第二次拉入群聊(或新建群聊),不会报错,但群聊表不会刷新,且不会触发监听事件,发送test无回复,且控制台无输出
  3. 机器人启动后被第三次拉入群聊(或新建群聊),不会报错,但群聊表不会刷新,且不会触发监听事件,发送test无回复,且控制台无输出
  4. 二次拉入群事件后 使机器人主动退出群聊或T出群聊,再次拉入该群,不会触发监听事件,发送test无回复,且控制台无输出

版本

mirai: 1.2.2

@XSana XSana added the t:problem 类型: 不容易归类为特性或 bug 的综合问题 label Sep 8, 2020
@mzdluo123
Copy link
Member

请问什么是第二次拉入群聊?是同一个群被踢出还是拉入另一个群。此外拉入群聊的详细过程是什么样的,是需要同意还是直接进入?

@XSana
Copy link
Author

XSana commented Sep 8, 2020

请问什么是第二次拉入群聊?是同一个群被踢出还是拉入另一个群。此外拉入群聊的详细过程是什么样的,是需要同意还是直接进入?

我这边观察和测试直接进入直接入群和同意入群都会发生,我测试时使用直接加入方式,之前手动同意也发生了次问题

以下测试均为直接加入

我的测试场景,共有3个群聊 群1 群2 群3
测试前(程序未启用状态)bot在群1,群2 群3无bot

启动程序后,将bot拉入群2,控制台报错,监听正常,群列表正常

将bot拉入群3,无报错,群里列表未刷新,不触发监听事件

使用测试指令使bot退出群1,再次将bot拉入群1,群里列表未刷新,不触发监听事件

将bot踢出群2,再次拉入bot,群里列表未刷新,不触发监听事件

@Him188 Him188 added the x:question 标签: 需要更多信息 label Sep 8, 2020
@Him188
Copy link
Member

Him188 commented Sep 9, 2020

属于接收不到好友消息 (MessageSvc) 的同类问题

@Him188 Him188 added z:duplicate 状态: 重复 and removed t:problem 类型: 不容易归类为特性或 bug 的综合问题 x:question 标签: 需要更多信息 labels Sep 9, 2020
@Him188
Copy link
Member

Him188 commented Sep 9, 2020

#249

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
t:bug 类型: bug x:protocol 属性: 协议相关 z:duplicate 状态: 重复
Projects
None yet
Development

No branches or pull requests

3 participants