Skip to content

Bot appears to hang if the client sends a command with an outdated command list #40

@AverageHelper

Description

@AverageHelper

To reproduce:

  1. Change the list of commands (perhaps by merging a PR into main)
  2. Update the bot
  3. Try to run the new command from a Desktop client, expecting the bot to reply
  4. (Occasionally) observe an apparent hang, and an error in the console about DiscordAPIError[10062]: Unknown interaction
  5. Reload your client
  6. Try the command again, should work fine.

Not sure why Discord sends the bot interactions that are "unknown" to it, so some research will be necessary. I suspect there's nothing that our bot can do if the interaction is "unknown," since it cannot reply to the user to say so. Perhaps the bot could avoid trying to reply to "unknown" interactions.

I wonder if the interaction's commandId property has useful information that we should be checking about the command invocation, rather than the name property. Will have to investigate further.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

Status

Ready for dev

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions