mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-08-27 20:40:13 +03:00
feat(agent): remove redundant done message from stream_chat
The `stream_chat` method was yielding a "done" message after streaming all chunks, but this is unnecessary as the streaming completion is already indicated by the end of the stream. Removing this redundant message simplifies the response handling and aligns with typical streaming patterns.
This commit is contained in:
parent
425ce43bdd
commit
289ae0cddf
@ -160,8 +160,6 @@ class AgentService:
|
||||
if chunk:
|
||||
yield chunk
|
||||
|
||||
yield {"type": "done", "session_id": session_id}
|
||||
|
||||
except Exception as e:
|
||||
log.error("Error in stream_chat: %s", e, exc_info=True)
|
||||
yield {"type": "error", "error": str(e), "session_id": session_id}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user