mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-09-06 12:06:45 +00:00
♻️ rewrite dependency injection system
This commit is contained in:
@ -1,13 +1,11 @@
|
||||
import inspect
|
||||
from typing import Any, Dict
|
||||
from typing import Any, Dict, Callable
|
||||
|
||||
from loguru import logger
|
||||
from pydantic.typing import ForwardRef, evaluate_forwardref
|
||||
|
||||
from nonebot.typing import T_Handler
|
||||
|
||||
|
||||
def get_typed_signature(call: T_Handler) -> inspect.Signature:
|
||||
def get_typed_signature(call: Callable[..., Any]) -> inspect.Signature:
|
||||
signature = inspect.signature(call)
|
||||
globalns = getattr(call, "__globals__", {})
|
||||
typed_params = [
|
||||
|
Reference in New Issue
Block a user