Проблема с командой для опроса discord.py
Да-да, знаю мне уже отвечали и код от местного программиста, но теперь другая проблема. Команда просто не хочет работать, а в терминале какой-то движ.

Код:
import datetime
import discord
import asyncio
import random
import re
from discord.ext import commands
from discord.ui.view import View
from discord.ui.modal import Modal
print("Starts...")
intents = discord.Intents.all()
bot = commands.Bot(command_prefix='g.',intents=intents)
class Poll_modal(Modal, title = '? | Опрос'):
ch = discord.ui.TextInput(label = "ID Канала:", placeholder = "Оставьте пустым, если опрос будет в этом канале", required = False)
name = discord.ui.TextInput(label = "Тема опроса:", required = True)
option_1 = discord.ui.TextInput(label = "Первый вариант ответа:", required = True)
option_2 = discord.ui.TextInput(label = "Второй вариант ответа:", required = True)
option_3 = discord.ui.TextInput(label = "Третий вариант ответа:", placeholder = "Этот вариант можно оставить пустым",required = False)
async def on_submit(self, interaction: discord.Interaction):
await interaction.response.defer()
one = f":one: {self.option_1.value}"
two = f":two: {self.option_2.value}"
if self.option_3.value == '':
three = ''
else:
three = f":three: {self.option_3.value}"
embed = discord.Embed(
title = '? | Опрос',
description = f"""
**{self.name.value}**
{one}
{two}
{three}""",
color = 0x007f5c
)
embed.set_footer(icon_url=settings.misc.avatar_url, text=settings.misc.footer)
embed.set_author(name = interaction.user.display_name, icon_url= interaction.user.display_avatar)
if self.ch.value == '':
msg = await interaction.channel.send(f'<@&{settings.roles.poll_role}>', embed=embed)
else:
channel = discord.utils.get(interaction.guild.channels, id = int(self.ch.value))
msg = await channel.send(f'<@&{settings.roles.poll_role}>', embed=embed)
await message.add_reaction('1️⃣')
await message.add_reaction('2️⃣')
if self.option_3.value != '':
await message.add_reaction('3️⃣')
class Poll(View):
def __init__(self, *, timeout=60):
super().__init__(timeout=timeout)
@discord.ui.button(emoji='?', style=discord.ButtonStyle.green, label = 'Создать опрос')
async def poll(self, interaction: discord.Interaction, button: discord.ui.Button):
await interaction.response.send_modal(Poll_modal())
class adm(commands.Cog):
def __init__(self, client):
self.client = client
@bot.command()
async def poll(self, ctx):
embed = discord.Embed(
title = "? | Опрос",
description = "",
color = 0x007f5c
)
embed.set_footer(icon_url = self.client.user.avatar.url, text = f'{self.client.user.name} | Все права защищены')
author = ctx.author
await ctx.send(embed = embed, view = Poll())
bot.run("TOKEN")