Throwing on unhandled interaction

Hey, I just wanted to quickly check this idea - If I assign a listener to interaction create and then set a 4 second timeout, if the interaction hasn't been deferred or replied to I can log an error right?
24418d ago
Log the error where exactly? Consol? Console
R
Rhys418d ago
I'll be logging it via sentry to track it
24418d ago
Yeah I don't see why you couldn't do this in an error listener for example Seems fine by me
R
Rhys418d ago
Is there a specific event thats emitted for this / all errors that I could just listen to? The other thing is getting information about what is failing, an error listener would need to let me know for example the id & name of what interaction didn't complete
24418d ago
I think you'd have to listen to xCommandError and make one for each of the different types of commands you have E.g. message, interaction and context Not sure what info you can get. I know you can parse the url but not sure of the context you get specifically. I'd try out and see what you can get
R
Rhys417d ago
GitHub
AnswerOverflow/command-failure.ts at bot-pre-release-polish · Answe...
Indexing Discord Help Channel Questions into Google - AnswerOverflow/command-failure.ts at bot-pre-release-polish · AnswerOverflow/AnswerOverflow
R
Rhys417d ago
Responds to failed interactions, logs to the console, and emits a message to sentry with command info
24417d ago
Nice!
Want results from more Discord servers?
Add your server
More Posts
Reply During CooldownCan I make the bot reply with the remaining time of cooldown delay ?messageUpdate event not Triggering```ts import { Listener } from '@sapphire/framework'; import type { Message } from 'discord.js'; exp'"discord.js"' has no exported member named 'WebhookEditMessageOptions'. Did you mean 'WebhookFetchMError: '"discord.js"' has no exported member named 'WebhookEditMessageOptions'. Did you mean 'WebhooMonoreposDoes Sapphire work and play nice with monorepos?Question regarding slash commands / aliasesHi, is there a way for me to register command aliases as slash commands as well? For example: Commandisable commands by dashboard.I want to disable commands through dashboard so, is there any way to dynamically disable commands ?What is the difference between response.status and response.statusCode ?When using the API Plugin of Sapphire.Hey what is DEVELOPMENT MODE and how do I disable itI tried setting the Node_Env to something else but it did not change it in the consoleBotList Autopost of stats is not workingI am using the bot list plugin https://github.com/devtomio/sapphire-plugin-botlist I set everything Miss matching objects on permission setting.Typescript says that permissionOverwrites does not exits in GuildBasedChannel, even tho it exists, irequiredClientPermissions check always rejectingWhile `requiredUserPermissions: ['ManageRoles']` works great. The client check `requiredClientPermisUnable to get member data from users that have left / kickedHi, I am trying to get data from members who have left the discord server or have been kicked. But ICatch all chat input command errors listenerHello ! I tried using the `Events.ChatInputCommandError` listener to catch any errors thrown by the Multiple Clients on one file/instanceI was wondering if its possible to run multiple clients on one file (i.e. .forEach()-ing `new ClientHow to present Slashcommands?How can I present the Slashcommands of my bot in his About Me like for example carl.gg does?Interaction HandlersAm I required to specify to sapphire where my interaction handlers directory is? A `interaction-handbot won't get on and connect to discord.hi, my bot won't turn on. i've coded a lot of bots before with sapphire and they worked just fine, dHow Do I Make a Project in my current Directory?I want to make the proj in `workspaces/DashMate` not like `workspaces/DashMate/${ProjName}`Bot wont go onlinewhen I try to run the script `yarn dev` I get this problemGuildDelete Event somehow gets triggered when I restart my BotI have no idea whats happening but if my bot (docker container) restarts, this notification gets sen