W
Size: a a a
W
W
ФК
import loggingЗдравствуйте! Я хотел сделать чтобы бот посылал сообщения и в то же время отвечал на мои, но почему-то хэндлер не работает
from aiogram import Bot, Dispatcher, executor, types
import asyncio
logging.basicConfig(level=logging.INFO)
bot = Bot(token='token')
dp = Dispatcher(bot)
@dp.message_handler(commands=['start', 'help'])
async def send_welcome(message: types.Message):
await message.reply("Hi!")
async def ts():
while True:
await asyncio.sleep(1)
await bot.send_message(myid, 'hello')
asyncio.run(ts())
executor.start_polling(dp, skip_updates=True)
ФК
Е
👑️
Е
👑️
import loggingЗдравствуйте! Я хотел сделать чтобы бот посылал сообщения и в то же время отвечал на мои, но почему-то хэндлер не работает
from aiogram import Bot, Dispatcher, executor, types
import asyncio
logging.basicConfig(level=logging.INFO)
bot = Bot(token='token')
dp = Dispatcher(bot)
@dp.message_handler(commands=['start', 'help'])
async def send_welcome(message: types.Message):
await message.reply("Hi!")
async def ts():
while True:
await asyncio.sleep(1)
await bot.send_message(myid, 'hello')
asyncio.run(ts())
executor.start_polling(dp, skip_updates=True)
ФК
Б
Е
Е
Е
Е
Е
Е
Е
👑️
Е
<Ч