Unknown Interaction error
10% of the time, when I'm running a command, I get the Unknown Interaction error for 1 or 2 minutes straight, and then it goes back to normal. I defer the reply at the top of every command (well inside the execute), I have a collector in only 1 of my commands and it does have the correct interaction object and I am the only one running the command so just 1 process is handling the same command (saying this cuz of the /tag thing). I'm guessing it has to do with my interactionCreate file. I asked for help in another discord js coding server and a mod there tried to help me fix it, but we couldn't so I'm posting it here.
15 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!
- ✅
Marked as resolved by OP(I need nitro for bigger messages so ill send the error in 2 seperate messxages)
Example of error:
here's my interactionCreate file: https://pastebin.com/WGUXkpZX
line 18 returns a promise, thats one thing
btw for the error, line 57 on warnings.js says
await interaction.deferReply()
on interactinCreate?
oh right
fetch
I just add an await inside the brackets right?define it beforehand
as for your unknown interaction, might be a host issue
i just run it in vsc console
so like
Basically
Not too sure if it rejects if there is no reply though
so ur saying if it's false we don't know if the promise is rejected or there just isnt an interaction?
shouldnt the
await
solve that?:property: ChatInputCommandInteraction#replied
@14.15.3
Whether this interaction has already been replied tothis also exists
along with .deferred
so
interaction.replied
checks if the interaction has been replied to and interaction.deferred
checks if it has been deferred.
makes sense
even if i replace it with this, the unknown interaction error still happensSeems like a network issue then
so if i get better network it's not gonna happen anymore? would make sense cuz currently im on vacation and from hotel wifi ig
Probably yes
ight thanks