mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Mute mypy python version bug
This commit is contained in:
parent
f7820b1f32
commit
1faa146eac
1 changed files with 3 additions and 2 deletions
|
|
@ -3,7 +3,6 @@ from __future__ import annotations
|
|||
import re
|
||||
from dataclasses import dataclass, field, replace
|
||||
from typing import (
|
||||
TYPE_CHECKING,
|
||||
Any,
|
||||
Dict,
|
||||
Iterable,
|
||||
|
|
@ -11,6 +10,7 @@ from typing import (
|
|||
Optional,
|
||||
Pattern,
|
||||
Sequence,
|
||||
TYPE_CHECKING,
|
||||
Union,
|
||||
cast,
|
||||
)
|
||||
|
|
@ -24,7 +24,8 @@ from aiogram.utils.deep_linking import decode_payload
|
|||
if TYPE_CHECKING:
|
||||
from aiogram import Bot
|
||||
|
||||
CommandPatternType = Union[str, re.Pattern[str], BotCommand]
|
||||
# TODO: rm type ignore after py3.8 support expiration or mypy bug fix
|
||||
CommandPatternType = Union[str, re.Pattern, BotCommand] # type: ignore[type-arg]
|
||||
|
||||
|
||||
class CommandException(Exception):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue