diff options
Diffstat (limited to '.venv/lib/python3.12/site-packages/uvicorn/middleware/asgi2.py')
-rw-r--r-- | .venv/lib/python3.12/site-packages/uvicorn/middleware/asgi2.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/.venv/lib/python3.12/site-packages/uvicorn/middleware/asgi2.py b/.venv/lib/python3.12/site-packages/uvicorn/middleware/asgi2.py new file mode 100644 index 00000000..75145f73 --- /dev/null +++ b/.venv/lib/python3.12/site-packages/uvicorn/middleware/asgi2.py @@ -0,0 +1,17 @@ +from uvicorn._types import ( + ASGI2Application, + ASGIReceiveCallable, + ASGISendCallable, + Scope, +) + + +class ASGI2Middleware: + def __init__(self, app: "ASGI2Application"): + self.app = app + + async def __call__( + self, scope: "Scope", receive: "ASGIReceiveCallable", send: "ASGISendCallable" + ) -> None: + instance = self.app(scope) + await instance(receive, send) |