最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

python - Aiogram is not handled - Stack Overflow

programmeradmin0浏览0评论

messages are not being processed

INFO:aiogram.event:Update id=794626540 is not handled. Duration 3 ms by bot id=7469046391

I'm not a programmer and I can't understand at all why it stopped reading the start message, explain how to work with the router and what did I do wrong?

I think there's something missing here, but I don't understand.

my code:

import asyncio
import logging

from aiogram import Bot, Dispatcher, types, F, Router
from aiogram.types import Message
from aiogram.filtersmand import Command
from aiogram.fsm.context import FSMContext
from aiogram.fsm.state import State, StatesGroup
from aiogram.utils.markdown import hbold, hlink
from aiogram.utils.chat_action import ChatActionSender


from config import TOKEN
from aiogram.fsm.storage.memory import MemoryStorage

storage = MemoryStorage()
dp = Dispatcher(storage=storage)
logging.basicConfig(level=logging.INFO)
bot = Bot(token=TOKEN)

class Form(StatesGroup):
    brand = State()
    model = State()
    year = State()
    vin = State()
    parts = State()
    problem = State()

questionnaire_router = Router()


@questionnaire_router.message(Command("start"))
async def start_questionnaire_process(message: Message):
    async with ChatActionSender.typing(bot=bot, chat_id=message.chat.id):
        await asyncio.sleep(2)
        await message.answer('Добро пожаловать в наш сервис! 
发布评论

评论列表(0)

  1. 暂无评论