DiscordIntegration

DiscordIntegration

3M Downloads

Exception when bot gets a PM

redsgreens opened this issue ยท 4 comments

commented

The following exception happens when someone sends a PM to the bot. After the exception happens, communication from Discord->Forge works but Forge->Discord is broken until Forge is restarted.

[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:print:289]: [09:07:14] [Warning] [JDASocket]: Got an unexpected Json-parse error. Please redirect following message to the devs:
        JSONObject["guild_id"] not found.
        CHANNEL_CREATE -> {"is_private":true,"last_message_id":"209703598421049347","recipient":{"id":"206256999242006528","avatar":"eb2c5cd8a92fb55b06af81ac757941f3","username":"Linc","discriminator":"3417"},"id":"209703597380730880","type":"text"}
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:print:289]: [09:07:14] [Fatal] [JDASocket]: Encountered an exception:
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]: java.lang.IllegalArgumentException: Could not find Private/Text Channel of id 209703597380730880
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.EntityBuilder.createMessage(EntityBuilder.java:484)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.MessageReceivedHandler.handleInternally(MessageReceivedHandler.java:44)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.SocketHandler.handle(SocketHandler.java:36)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.requests.WebSocketClient.handleEvent(WebSocketClient.java:545)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.requests.WebSocketClient.onTextMessage(WebSocketClient.java:296)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ListenerManager.callOnTextMessage(ListenerManager.java:352)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:233)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:211)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.handleTextFrame(ReadingThread.java:910)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:693)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:102)
[09:07:14] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.run(ReadingThread.java:61)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:print:289]: [09:07:18] [Fatal] [JDASocket]: Encountered an exception:
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]: java.lang.IllegalArgumentException: Could not find Private/Text Channel of id 209703597380730880
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.EntityBuilder.createMessage(EntityBuilder.java:484)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.MessageReceivedHandler.handleInternally(MessageReceivedHandler.java:44)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.handle.SocketHandler.handle(SocketHandler.java:36)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.requests.WebSocketClient.handleEvent(WebSocketClient.java:545)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.net.dv8tion.jda.requests.WebSocketClient.onTextMessage(WebSocketClient.java:296)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ListenerManager.callOnTextMessage(ListenerManager.java:352)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:233)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.callOnTextMessage(ReadingThread.java:211)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.handleTextFrame(ReadingThread.java:910)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:693)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:102)
[09:07:18] [ReadingThread/INFO] [STDERR/ChikachiDiscord]: [chikachi.discord.repack.net.dv8tion.jda.utils.SimpleLog:log:226]:    at chikachi.discord.repack.com.neovisionaries.ws.client.ReadingThread.run(ReadingThread.java:61)
commented

Would be nice to have the MC version and mod version, but I'm pretty sure that's an issue because JDA needs updating as indicated by #10

commented

Sorry, this is Forge 1.8.9 build 1855 and ChikachiDiscord-mc1.8.9-1.3.0.

commented

Could you try using 1.4.0 that just got released?
It contains the updated JDA (library for communication with Discord)

commented

Updating to 1.4.0 seems to have fixed the issue. Thank you!