diff --git a/aio_request/pipeline.py b/aio_request/pipeline.py index 813ffac..3d5fcc9 100644 --- a/aio_request/pipeline.py +++ b/aio_request/pipeline.py @@ -14,7 +14,6 @@ from .response_classifier import ResponseClassifier, ResponseVerdict from .transport import Transport - try: import prometheus_client as prom @@ -51,9 +50,7 @@ ), ) - def capture_metrics( - *, endpoint: yarl.URL, request: Request, status: int, started_at: float - ) -> None: + def capture_metrics(*, endpoint: yarl.URL, request: Request, status: int, started_at: float) -> None: label_values = ( endpoint.human_repr(), request.method, @@ -65,11 +62,10 @@ def capture_metrics( except ImportError: - def capture_metrics( - *, endpoint: yarl.URL, request: Request, status: int, started_at: float - ) -> None: + def capture_metrics(*, endpoint: yarl.URL, request: Request, status: int, started_at: float) -> None: pass + NextModuleFunc = collections.abc.Callable[ [yarl.URL, Request, Deadline, Priority], collections.abc.Awaitable[ClosableResponse] ]