ctx.respond can't send file
Summary
Trying to send a file (e.g. image) with ctx.respond ends up in TypeError: send_message() got an unexpected keyword argument 'file'.
Reproduction Steps
Try to send a file with ctx.respond
Minimal Reproducible Code
ctx.respond(embed=embed, file=my_file_variable)
Expected Results
Send the file
Actual Results
Ignoring exception in command <discord.app.commands.SlashCommand name=graph>: Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/discord/app/commands.py", line 85, in wrapped ret = await coro(arg) File "/usr/local/lib/python3.9/dist-packages/discord/app/commands.py", line 445, in _invoke await self.callback(self.cog, ctx, **kwargs) File "/root/invitechecker/test/engine/sl_pub_func.py", line 72, in visualize_data await ctx.respond(embed=em, file=file) TypeError: send_message() got an unexpected keyword argument 'file'
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/discord/bot.py", line 227, in process_application_commands await ctx.command.invoke(ctx) File "/usr/local/lib/python3.9/dist-packages/discord/app/commands.py", line 135, in invoke await injected(ctx) File "/usr/local/lib/python3.9/dist-packages/discord/app/commands.py", line 91, in wrapped raise ApplicationCommandInvokeError(exc) from exc discord.app.errors.ApplicationCommandInvokeError: Application Command raised an exception: TypeError: send_message() got an unexpected keyword argument 'file'
Intents
members
System Information
Python 3.9.4
Checklist
- [X] I have searched the open issues for duplicates.
- [X] I have shown the entire traceback, if possible.
- [X] I have removed my token from display, if visible.
Additional Context
Using slash branch.
Files have been done in #263, master branch
Will this be inclued in slash branch soon or are these different ?
Yes.