MCPcopy Create free account
hub / github.com/pallets/quart / __call__

Method __call__

tests/test_testing.py:440–459  ·  view source on GitHub ↗
(
            self, scope: dict, receive: Callable, send: Callable
        )

Source from the content-addressed store, hash-verified

438 self.app = app
439
440 async def __call__(
441 self, scope: dict, receive: Callable, send: Callable
442 ) -> None:
443 if scope["path"] != "/":
444 await send(
445 {
446 "type": "http.response.start",
447 "status": 401,
448 "headers": [(b"content-length", b"0")],
449 }
450 )
451 await send(
452 {
453 "type": "http.response.body",
454 "body": b"",
455 "more_body": False,
456 }
457 )
458 else:
459 await self.app(scope, receive, send)
460
461 app.asgi_app = OddMiddleware(app.asgi_app) # type: ignore
462

Callers

nothing calls this directly

Calls 1

sendFunction · 0.85

Tested by

no test coverage detected