mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-09-07 04:26:45 +00:00
🧑💻 Develop: 添加 ruff RUF 规则 (#2598)
Co-authored-by: Ju4tCode <42488585+yanyongyu@users.noreply.github.com>
This commit is contained in:
@ -1,13 +1,13 @@
|
||||
import asyncio
|
||||
from contextlib import AsyncExitStack
|
||||
from typing import Set, Union, NoReturn, Optional
|
||||
from typing import Set, List, Type, Union, ClassVar, NoReturn, Optional
|
||||
|
||||
from nonebot.dependencies import Dependent
|
||||
from nonebot.exception import SkippedException
|
||||
from nonebot.typing import T_State, T_RuleChecker, T_DependencyCache
|
||||
|
||||
from .adapter import Bot, Event
|
||||
from .params import BotParam, EventParam, StateParam, DependParam, DefaultParam
|
||||
from .params import Param, BotParam, EventParam, StateParam, DependParam, DefaultParam
|
||||
|
||||
|
||||
class Rule:
|
||||
@ -28,7 +28,7 @@ class Rule:
|
||||
|
||||
__slots__ = ("checkers",)
|
||||
|
||||
HANDLER_PARAM_TYPES = [
|
||||
HANDLER_PARAM_TYPES: ClassVar[List[Type[Param]]] = [
|
||||
DependParam,
|
||||
BotParam,
|
||||
EventParam,
|
||||
|
Reference in New Issue
Block a user