MCPcopy Create free account
hub / github.com/CommonstackAI/UncommonRoute / _open_stream_attempt

Function _open_stream_attempt

uncommon_route/proxy.py:5391–5399  ·  view source on GitHub ↗
(attempt_payload: dict[str, Any])

Source from the content-addressed store, hash-verified

5389 stream_record_state["done"] = True
5390
5391 async def _open_stream_attempt(attempt_payload: dict[str, Any]) -> httpx.Response:
5392 client = _get_client()
5393 req = client.build_request(
5394 "POST",
5395 attempt_payload["target_chat_url"],
5396 json=attempt_payload["transport_body"],
5397 headers=attempt_payload["headers"],
5398 )
5399 return await client.send(req, stream=True)
5400
5401 async def _select_stream_response() -> tuple[httpx.Response | None, Response | None]:
5402 fallback_source_model: str | None = None

Callers 1

_select_stream_responseFunction · 0.85

Calls 3

_get_clientFunction · 0.85
build_requestMethod · 0.80
sendMethod · 0.80

Tested by

no test coverage detected