zfbx / zdiscord

A Discord bot that runs in FiveM for the purpose of whitelisting, moderation and utilties using discord.js
Other
210 stars 79 forks source link

[BUG] - Failed to fetch Discord server #100

Open KodakZack opened 12 months ago

KodakZack commented 12 months ago

Describe the bug I keep receiving "Failed to fetch Discord server" every couple of days. I got it working yesterday and it has been fine since but after I just restarted my dev server again I am now getting this error. I have tried to reset my token but that didnt work either. I dont know what else to do. This issue only started recently. Could it be a fivem artifact issue?

Expected behavior Discord bot connects and runs smoothly.

Screenshots https://i.imgur.com/d0NJ3Ow.png

Information:

Additional context Add any other context about the problem here.

zfbx commented 12 months ago

The errors in your screenshot suggest you don't have the token or server id set in the config? but another thing you can do to see more about what's going on is enable DebugLogs in the config. that should tell you more about what could be going wrong if it is api related

KodakZack commented 12 months ago

https://i.imgur.com/HzpoBja.png I just ensured it again and I get the same errors but then the bot connects and works fine. Is this just an API error? I enabled DebugLogs but nothing showed since it connected this time.

zfbx commented 12 months ago

wait.. that's not a zdiscord error 👀 not sure what srp-core is but zdiscord errors log with this own timestamps wait 🤔 is it? why does that look weird?

KodakZack commented 12 months ago

Its my core with component loggers but I do use qbcore

zfbx commented 12 months ago

does it modify zdiscord?

KodakZack commented 12 months ago

No it does not. At the moment everything is working normally.

zfbx commented 12 months ago

follow up, do you use webhook logging? and if so.. excessively?

KodakZack commented 12 months ago

I do not. I have that disabled.

zfbx commented 12 months ago

hmm weird.. maybe it's just when the discord api goes down for a bit? that or you're on a host that has other people hammering the discord api? not sure :( debuglogs will paint a better picture when it happens but they're pretty spammy till then sadly

KodakZack commented 12 months ago

I will follow up if it does happen again and I will make sure to get the debuglogs. I appreciate the help regardless!