bug: client crashes while parsing discord system messages
hideonrosie opened this issue · 3 comments
Issue checklist
- I have checked the FAQs.
- I have searched the existing issues to make sure this isn't a duplicate.
- I have discussed this issue on the support server.
Issue description
So, i just got botclient crashed when switching from other channel to a channel that have AutoMod logging
Here is the crash report:
TypeError: Cannot read properties of undefined (reading 'startsWith')
at r (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:1698255)
at discord-messages
at _ (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:115420)
at DiscordMessages
at main
at div
at div
at r (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:1689800)
at div
at div
at n (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:1672985)
at div
at div
at div
at div
at div
at div
at n (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:1720516)
at n (file:///C:/Users/Admin/AppData/Local/Programs/botclient/resources/app.asar/build/static/js/main.89189ca3.js:2:1598774)
Current behavior
No response
Expected behavior
No response
BotClient version
v0.10.3
Operating System
Windows 10 21H2. Build 19044.1826
How did you download the application?
From GitHub releases (or links from the readme)
Priority this issue should have
Medium (should be fixed soon)
Addition information
No response
Can you give information on the channel that's causing the said error?
Like, channel-type, permissions, etc
Also, my closest guess is it's something to do with weird messages but i cant say for sure until I can reproduce the crash.
This is that channel Information
Type: TEXT Channel
Permmissions:
- Bot: Admin Permmission
- Channel: Everyone: View channel, view message history, send messages, react, embed file and link
In the server, I dedicate this channel to storing AutoMod logs, so I think AutoMod is the reason for this problem. Because then I tried deleting all Discord System messages and the Client didn't crash anymore
Sorry for the late reply, I've been busy studying for exams lately
Yup, it's definitely an issue with Discord System messages. The only ones that are currently being parsed appropriately are the user joining messages.
The message parser is mostly legacy code from early days of the client and needs to be rewritten. This issue will be fixed at the same time 👍
Sorry for the late reply, I've been busy studying for exams lately
Np! Tysm for taking the time to file this report and helping us out!