2022-04-26 20:22:55.245 ERROR 17960 --- [atcher-worker-1] love.forte.simbot.mirai.bot.3504929659 : Exception in coroutine 'Bot.3504929659'.
java.util.NoSuchElementException: net.mamoe.mirai.message.data.MessageSource$Key@601d4d7f
at love.forte.simbot.component.mirai.event.MiraiReceivedMessageContentKt.toSimbotMessageContent(MiraiReceivedMessageContent.kt:118) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at love.forte.simbot.component.mirai.event.impl.MiraiFriendMessagePostSendEventImpl.<init>(MiraiFriendMessagePostSendEventImpl.kt:42) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at love.forte.simbot.component.mirai.internal.MiraiBotImplKt$registerEvents$1$invokeSuspend$$inlined$doHandler$34.invokeSuspend(MiraiBotImpl.kt:497) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) ~[kotlin-stdlib-1.6.10.jar:1.6.10-release-923(1.6.10)]
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
2022-04-26 20:22:55.417 ERROR 17960 --- [atcher-worker-1] love.forte.simbot.mirai.bot.3504929659 : Exception in coroutine 'Bot.3504929659'.
java.util.NoSuchElementException: net.mamoe.mirai.message.data.MessageSource$Key@601d4d7f
at love.forte.simbot.component.mirai.event.MiraiReceivedMessageContentKt.toSimbotMessageContent(MiraiReceivedMessageContent.kt:118) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at love.forte.simbot.component.mirai.event.impl.MiraiFriendMessagePostSendEventImpl.<init>(MiraiFriendMessagePostSendEventImpl.kt:42) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at love.forte.simbot.component.mirai.internal.MiraiBotImplKt$registerEvents$1$invokeSuspend$$inlined$doHandler$34.invokeSuspend(MiraiBotImpl.kt:497) ~[simbot-component-mirai-core-3.0.0.0.preview.2.0.jar:na]
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) ~[kotlin-stdlib-1.6.10.jar:1.6.10-release-923(1.6.10)]
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665) ~[kotlinx-coroutines-core-jvm-1.5.2.jar:na]
关键代码如下
报错信息如下