MCPcopy
hub / github.com/nonebot/nonebot2 / request_handler

Function request_handler

tests/fake_server.py:137–141  ·  view source on GitHub ↗
(request: Request)

Source from the content-addressed store, hash-verified

135
136@Request.application
137def request_handler(request: Request) -> Response:
138 if request.headers.get("Connection") == "Upgrade":
139 return websocket_echo(request)
140 else:
141 return http_echo(request)

Callers

nothing calls this directly

Calls 3

websocket_echoFunction · 0.85
http_echoFunction · 0.85
getMethod · 0.45

Tested by

no test coverage detected