Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bot stops working after a bit and gives "Unknown Message, code: 10008" error #430

Open
MrD4rio opened this issue Jan 2, 2024 · 8 comments

Comments

@MrD4rio
Copy link

MrD4rio commented Jan 2, 2024

This issue occurs when sending a message on Discord to have it relayed to Telegram.
As soon as the bot is started messages are getting relayed correctly, however after a bit (in this case I've noticed a few hours later) messages do not get relayed anymore.

After restarting the bot messages from Discord are relayed correctly, but if I leave it running and try sending a new message after 1 hour or so I get the same error and the message doesn't get relayed.

Here's the error I get:

      throw new DiscordAPIError(data, "code" in data ? data.code : data.error, status, method, url, requestData);
            ^

DiscordAPIError[10008]: Unknown Message
    at handleErrors (/home/ubuntu/TediCross/node_modules/@discordjs/rest/dist/index.js:687:13)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async SequentialHandler.runRequest (/home/ubuntu/TediCross/node_modules/@discordjs/rest/dist/index.js:1072:23)
    at async SequentialHandler.queueRequest (/home/ubuntu/TediCross/node_modules/@discordjs/rest/dist/index.js:913:14)
    at async _REST.request (/home/ubuntu/TediCross/node_modules/@discordjs/rest/dist/index.js:1218:22)
    at async GuildMessageManager.delete (/home/ubuntu/TediCross/node_modules/discord.js/src/managers/MessageManager.js:259:5)
    at async Message.delete (/home/ubuntu/TediCross/node_modules/discord.js/src/structures/Message.js:816:5) {
  requestBody: { files: undefined, json: undefined },
  rawError: { message: 'Unknown Message', code: 10008 },
  code: 10008,
  status: 404,
  method: 'DELETE',
  url: 'https://discord.com/api/v10/channels/950543982956535829/messages/1191814675608916050'
}

In my settings I have the bridge mode set to d2t, I've also tried setting it to "both" but the situation is the same, as soon as the bot is started it works fine, after a bit it stops working and gives that error.

@Lulalaby
Copy link
Collaborator

Lulalaby commented Jan 3, 2024

This issue occurs when sending a message on Discord to have it relayed to Telegram.

it's clearly doing a message deletion tho

@MrD4rio
Copy link
Author

MrD4rio commented Jan 3, 2024

it's clearly doing a message deletion tho

For some reason the error appeared as soon as I sent a message in the channel

@LeroyJankins
Copy link

it's clearly doing a message deletion tho

same issue for me, same code same error

@LeroyJankins
Copy link

You should use interaction.reply(...) instead of interaction.followUp(...)

the fix if someone can apply it , because I dont know where do I edit it

@Lulalaby
Copy link
Collaborator

Lulalaby commented Jan 7, 2024

Interactions aren't used at all in the bots, except for the two slash commands chatinfo & threadinfo.
This has literally nothing to do with normal text messages, so it won't fix anything.

@LeroyJankins
Copy link

Interactions aren't used at all in the bots, except for the two slash commands chatinfo & threadinfo. This has literally nothing to do with normal text messages, so it won't fix anything.

Any idea of what might cause it?

@LeroyJankins
Copy link

the bug is clearly happening when deleting a message in discord

@Pecacheu
Copy link

Having the same bug here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants