channel = await bot.fetch_channel(self.channel)
message = await channel.fetch_message(self.message)
print(message)
Эти три строчки отказываются работать и выдают:
Traceback (most recent call last):
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\bot.py", line 1113, in invoke_application_command
await ctx.command.invoke(ctx)
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\commands\core.py", line 374, in invoke
await injected(ctx)
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\commands\core.py", line 132, in wrapped
raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: NotFound: 404 Not Found (error code: 10062): Unknown interaction
Ignoring exception in view <MyView timeout=180.0 children=4> for item <Button style=<ButtonStyle.primary: 1> url=None disabled=False label='Удалить' emoji=None row=1>:
Traceback (most recent call last):
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\ui\view.py", line 414, in _scheduled_task
await item.callback(interaction)
File "C:\Users\ivanb\PycharmProjects\Integrator2\main.py", line 65, in fourth_button_callback
message = await channel.fetch_message(self.message)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\abc.py", line 1666, in fetch_message
data = await self._state.http.get_message(channel.id, id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\ivanb\PycharmProjects\Integrator2\venv\Lib\site-packages\discord\http.py", line 363, in request
raise NotFound(response, data)
discord.errors.NotFound: 404 Not Found (error code: 10008): Unknown Message
Все переменные заданы, канал находит, сообщение - нет.