Closed wa1ker38552 closed 2 years ago
The application shows a 'did not respond' message even after it has already responded.
Create and send a command
import discord # functions def create_embed(em): embed = discord.Embed() embed.title = em['title'] embed.color = em['color'] embed.description = em['description'] return embed client = discord.Bot() @client.event async def on_ready(): print(client.user) @client.command(description='Show debug information') async def debug(ctx): embed = create_embed({ 'title': 'Debug', 'color': 0x338CFF, 'description': f'**Latency: **`{round(client.latency, 3)}` ms' }) await ctx.send(embed=embed) client.run('TOKEN')
The application returns a response
The application returned a response but also showed an error message. As you can see, the application responded twice.
discord.Intents.default()
I don't know why it says 10, i'm using 11. Running on pycharm.
No response
To respond to an interaction, you should use ctx.respond.
ctx.respond
Thank you, I could not find documentation for that when I searched the question.
Summary
The application shows a 'did not respond' message even after it has already responded.
Reproduction Steps
Create and send a command
Minimal Reproducible Code
Expected Results
The application returns a response
Actual Results
The application returned a response but also showed an error message. As you can see, the application responded twice.
Intents
discord.Intents.default()
System Information
I don't know why it says 10, i'm using 11. Running on pycharm.
Checklist
Additional Context
No response