HKUDS/nanobot · error · ConnectionError
SSE connection failed with status {response.status_code}
Error message
SSE connection failed with status {response.status_code} What it means
Error "SSE connection failed with status {response.status_code}" thrown in HKUDS/nanobot.
Source
Thrown at nanobot/channels/signal/runtime.py:615
raise
finally:
# Keep typing active across progress updates; stop on the final reply.
if not is_progress_message:
# Avoid immediate START->STOP for fast responses, which can be invisible
# in some Signal clients. Let indicator expire naturally (~15s).
await self._stop_typing(msg.chat_id, send_stop=False)
async def _sse_receive_loop(self) -> None:
"""Receive messages via Server-Sent Events (HTTP mode)."""
if not self._http:
raise RuntimeError("HTTP client not initialized for Signal SSE stream")
self.logger.info("Started Signal message receive loop (SSE)")
try:
async with self._http.stream("GET", "/api/v1/events") as response:
if response.status_code != 200:
raise ConnectionError(
f"SSE connection failed with status {response.status_code}"
)
self.logger.info("Subscribed to Signal messages via SSE")
# Buffer for accumulating SSE data across multiple lines
event_buffer: list[str] = []
async for line in response.aiter_lines():
if not self._running:
break
# Debug: log raw SSE lines (except keepalive pings)
if line and line != ":":
self.logger.debug("SSE line received: {}", line[:200])
# SSE format handling
if isinstance(line, str): # pyright: ignore[reportUnnecessaryIsInstance]View on GitHub (pinned to 42f37dc4c0)
When it happens
Trigger: Thrown at nanobot/channels/signal/runtime.py:615 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of HKUDS/nanobot@42f37dc4c0 (2026-08-26).
Data as JSON: /api/errors/7b5278dfeea94305.
Report an issue: GitHub.