Back to Prefect

subscriptions

docs/v3/api-ref/python/prefect-server-utilities-subscriptions.mdx

3.6.30.dev3774 B
Original Source

prefect.server.utilities.subscriptions

Functions

accept_prefect_socket <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/server/utilities/subscriptions.py#L20" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>

python
accept_prefect_socket(websocket: WebSocket) -> Optional[WebSocket]

still_connected <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/server/utilities/subscriptions.py#L103" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>

python
still_connected(websocket: WebSocket) -> bool

Checks that a client websocket still seems to be connected during a period where the server is expected to be sending messages.