Using bot.wait_for() to get the modal popped up using the event on_modal
Submit the modal
async for cmd in channel.slash_commands(query='post'):
if cmd.name == 'post':
await cmd()
def check(m):
return m.title == "Need clanmates post"
modal = await bot.wait_for("modal", check=check)
await modal.submit()
Code
No response
Expected Results
Modal submitted.
Actual Results
Task exception was never retrieved
future: <Task finished name='Task-14' coro=<post_23h_task() done, defined at /Users/PycharmProjects/James Projects/Bots Stuff/Discord Bot/Post Bot/main.py:88> exception=NotImplementedError()>
Traceback (most recent call last):
File "/Users/PycharmProjects/James Projects/Bots Stuff/Discord Bot/Post Bot/main.py", line 129, in post_23h_task
await modal.submit()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 136, in submit
self.to_dict(),
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 104, in to_dict
'components': [c.to_dict() for c in self.components],
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 104, in
'components': [c.to_dict() for c in self.components],
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/components.py", line 102, in to_dict
raise NotImplementedError
NotImplementedError
System Information
discord.py-self==2.0.0
python3.9
Checklist
[X] I have searched the open issues for duplicates.
[X] I have shared the entire traceback.
[X] I am using a user token (and it isn't visible in the code).
Summary
Tried using modal.submit for a slash command.
Reproduction Steps
bot.wait_for()
to get the modal popped up using the eventon_modal
Code
No response
Expected Results
Modal submitted.
Actual Results
Task exception was never retrieved future: <Task finished name='Task-14' coro=<post_23h_task() done, defined at /Users/PycharmProjects/James Projects/Bots Stuff/Discord Bot/Post Bot/main.py:88> exception=NotImplementedError()> Traceback (most recent call last): File "/Users/PycharmProjects/James Projects/Bots Stuff/Discord Bot/Post Bot/main.py", line 129, in post_23h_task await modal.submit() File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 136, in submit self.to_dict(), File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 104, in to_dict 'components': [c.to_dict() for c in self.components], File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/modal.py", line 104, in
'components': [c.to_dict() for c in self.components],
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/discord/components.py", line 102, in to_dict
raise NotImplementedError
NotImplementedError
System Information
discord.py-self==2.0.0 python3.9
Checklist
Additional Information
No response