@zhaodice 在 目前可用的插件开发调试方案 中说:
可以用这个
直接安装release插件即可正常登录,手表只能扫码,apad/android只能密码且需要手动抓ticket:
https://github.com/MrXiaoM/fpv/releases
这个方法很好,感谢!目前采用插件+签名方法,主域名貌似老是被打,所以得换备份?至少我是没用主域名上成。
@zhaodice 在 目前可用的插件开发调试方案 中说:
可以用这个
直接安装release插件即可正常登录,手表只能扫码,apad/android只能密码且需要手动抓ticket:
https://github.com/MrXiaoM/fpv/releases
这个方法很好,感谢!目前采用插件+签名方法,主域名貌似老是被打,所以得换备份?至少我是没用主域名上成。
想问一下目前可用的Intellij IDEA开发调试方案。因为目前只凭借build sandbox,也就是普通的mirai console貌似基本上必定45,我想应该可以连接到类似LLOneBot之类的地方,就可以测试收发消息;或者凭借签名服务(之前其实也搞过,但是部署起来略显麻烦个人认为而已),所以想问一下各位都是怎么调试自己的插件的。
插个眼,我现在有个号用安卓手机实体机8.9.80能上,但是mirai 2.15.0用qsign ANDROID_PHONE 8.9.70死活code 45
说实话不太敢往上升,我不确定是我的mirai配置问题还是账号问题
Mirai版本:Mirai console 2.16.0
fix-protocol-version v1.9.9
mirai-api-http v2.9.1
当前各登录协议版本日期:
ANDROID_PHONE 8.9.58.11170 2023-05-19T11:35+08:00
ANDROID_PAD 8.9.58.11170 2023-05-19T11:35+08:00
ANDROID_WATCH 2.0.8 2019-06-03T20:25:31+08:00
IPAD 8.9.50.611 2023-02-16T15:10:14+08:00
MACOS 6.8.2.21241 2022-03-14T11:11:35+08:00
v8.9.58 by kiliokuara/magic-signer-guide from http://someplace.from.my.network
完整的Exception(QQ号码掉了)
2023-12-19 16:17:11 W/stderr: net.mamoe.mirai.event.ExceptionInEventHandlerException: Exception in EventHandler
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.event.JvmMethodListenersInternal.registerEventHandler$callMethod$invokeWithErrorReport(JvmMethodListenersInternal.kt:155)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.event.JvmMethodListenersInternal.access$registerEventHandler$callMethod$invokeWithErrorReport(JvmMethodListenersInternal.kt:26)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.event.JvmMethodListenersInternal$registerEventHandler$callMethod$2.invokeSuspend(JvmMethodListenersInternal.kt:162)
2023-12-19 16:17:11 W/stderr: at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.internal.LimitedDispatcher.run(LimitedDispatcher.kt:42)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:95)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:570)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:677)
2023-12-19 16:17:11 W/stderr: at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:664)
2023-12-19 16:17:11 W/stderr: Caused by: java.lang.reflect.InvocationTargetException
2023-12-19 16:17:11 W/stderr: at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(Unknown Source)
2023-12-19 16:17:11 W/stderr: at java.base/java.lang.reflect.Method.invoke(Unknown Source)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.event.JvmMethodListenersInternal.registerEventHandler$callMethod$invokeWithErrorReport(JvmMethodListenersInternal.kt:148)
2023-12-19 16:17:11 W/stderr: ... 10 more
2023-12-19 16:17:11 W/stderr: Caused by: java.lang.IllegalStateException: Session(bot=2302558203) Invalid authorization format: Cannot verify authorization format.
2023-12-19 16:17:11 W/stderr: at fix-protocol-version-1.9.9.mirai2.jar//xyz.cssxsh.mirai.tool.ViVo50$Session.check(ViVo50.kt:358)
2023-12-19 16:17:11 W/stderr: at fix-protocol-version-1.9.9.mirai2.jar//xyz.cssxsh.mirai.tool.ViVo50$Session.websocket(ViVo50.kt:395)
2023-12-19 16:17:11 W/stderr: at fix-protocol-version-1.9.9.mirai2.jar//xyz.cssxsh.mirai.tool.ViVo50$Session.sendPacket(ViVo50.kt:407)
2023-12-19 16:17:11 W/stderr: at fix-protocol-version-1.9.9.mirai2.jar//xyz.cssxsh.mirai.tool.ViVo50$Session.sendCommand(ViVo50.kt:420)
2023-12-19 16:17:11 W/stderr: at fix-protocol-version-1.9.9.mirai2.jar//xyz.cssxsh.mirai.tool.ViVo50.qSecurityGetSign(ViVo50.kt:234)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.network.protocol.packet.OutgoingPacketKt.buildRawUniPacket(OutgoingPacket.kt:139)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.network.protocol.packet.chat.receive.MessageSvcPbSendMsg.createToFriendImpl$mirai_core(MessageSvc.PbSendMsg.kt:694)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.network.protocol.packet.chat.receive.MessageSvc_PbSendMsgKt.createToFriend(MessageSvc.PbSendMsg.kt:564)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.outgoing.FriendMessageProtocolStrategy.createPacketsForGeneralMessage(MessageProtocolStrategy.kt:82)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.outgoing.FriendMessageProtocolStrategy.createPacketsForGeneralMessage(MessageProtocolStrategy.kt:71)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.impl.GeneralMessageSenderProtocol$GeneralMessageSender.process(GeneralMessageSenderProtocol.kt:66)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.outgoing.OutgoingMessageProcessorAdapter.process(OutgoingMessagePipelineProcessor.kt:26)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.outgoing.OutgoingMessageProcessorAdapter.process(OutgoingMessagePipelineProcessor.kt:20)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.pipeline.AbstractProcessorPipeline.process$suspendImpl(ProcessorPipeline.kt:287)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.pipeline.AbstractProcessorPipeline.process(ProcessorPipeline.kt)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.MessageProtocolFacadeImpl.preprocessAndSendOutgoingImpl(MessageProtocolFacade.kt:364)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.MessageProtocolFacadeImpl.preprocessAndSendOutgoing(MessageProtocolFacade.kt:348)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.message.protocol.MessageProtocolFacade$INSTANCE.preprocessAndSendOutgoing(MessageProtocolFacade.kt)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.contact.AbstractUserKt.sendMessageImpl(AbstractUser.kt:263)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.internal.contact.FriendImpl.sendMessage(FriendImpl.kt:102)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.contact.Friend.sendMessage$suspendImpl(Friend.kt:93)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.contact.Friend.sendMessage(Friend.kt)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.contact.Friend$sendMessage$3.invoke(Friend.kt)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.contact.Friend$sendMessage$3.invoke(Friend.kt)
2023-12-19 16:17:11 W/stderr: at kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsJvmKt$createCoroutineUnintercepted$$inlined$createCoroutineFromSuspendFunction$IntrinsicsKt__IntrinsicsJvmKt$1.invokeSuspend(IntrinsicsJvm.kt:205)
2023-12-19 16:17:11 W/stderr: at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
2023-12-19 16:17:11 W/stderr: at kotlin.coroutines.ContinuationKt.startCoroutine(Continuation.kt:115)
2023-12-19 16:17:11 W/stderr: at me.him188.kotlin.jvm.blocking.bridge.internal.RunSuspendKt.$runSuspend$(RunSuspend.kt:18)
2023-12-19 16:17:11 W/stderr: at net.mamoe.mirai.contact.Friend.sendMessage(Friend.kt)
2023-12-19 16:17:11 W/stderr: at RongXiaoliBot-0.2.1-Preview1.mirai2.jar//com.rongxiaoli.module.Ping.Ping.FriendMain(Ping.java:52)
2023-12-19 16:17:11 W/stderr: at RongXiaoliBot-0.2.1-Preview1.mirai2.jar//com.rongxiaoli.MessageProcessor.FriendMessageProcess(MessageProcessor.java:36)
2023-12-19 16:17:11 W/stderr: at RongXiaoliBot-0.2.1-Preview1.mirai2.jar//com.rongxiaoli.PluginListener.onFriendMessage(PluginListener.java:28)
2023-12-19 16:17:11 W/stderr: ... 13 more
以及第二个账号登陆的时候卡在这里(debug消息,IP我码了):
2023-12-19 16:16:04 D/org.asynchttpclient.netty.channel.DefaultChannelPool: Entry count for : http://someplace.from.my.network:8888 : 1
2023-12-19 16:16:05 D/org.asynchttpclient.netty.channel.DefaultChannelPool: Entry count for : http://someplace.from.my.network:8888 : 1
2023-12-19 16:16:06 D/org.asynchttpclient.netty.channel.DefaultChannelPool: Entry count for : http://someplace.from.my.network:8888 : 1
🤔
代码改成了
Group group = (Group) e.getSubject();
group.sendMessage("就你会戳吗?");
e.getFrom().nudge().sendTo(e.getSubject());
目的达到了
(看起来报错不是我的问题)
奇怪,没法复现
ps:我的代码写错了,应为:
Group group = (Group) e.getSubject();
group.sendMessage("就你会戳吗?");
MemberNudge memberNudge = new MemberNudge((NormalMember) e.getFrom());
memberNudge.sendTo((Contact) e.getFrom());
ps:ps:这段代码好像并不能在群里戳群成员,而是私聊并戳一戳