Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for iscoroutinefunction (0.05 sec)

  1. fastapi/routing.py

    def websocket_session(
        func: Callable[[WebSocket], Awaitable[None]],
    ) -> ASGIApp:
        """
        Takes a coroutine `func(session)`, and returns an ASGI application.
        """
        # assert asyncio.iscoroutinefunction(func), "WebSocket endpoints must be async"
    
        async def app(scope: Scope, receive: Receive, send: Send) -> None:
            session = WebSocket(scope, receive=receive, send=send)
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 174.6K bytes
    - Viewed (0)
Back to top