Dev - #26
Merged
Merged
Conversation
When the agent stream failed (timeout, connection error, etc.), the backend sent an error event to the client but never pushed it into the events array. The error was not visible in the frontend UI because the post-stream message refresh fetched from the DB, which had no record of the error. Push the error event into the events array in all three catch blocks (sendMessage, sendPermission, sendClarification) before saving the AI message to the DB. Move the events declaration outside the try block in sendPermission and sendClarification so it is accessible in the catch block. Add the error event type to the Event union.
…504s agentFetch applied AbortSignal.timeout(100s) to all agent requests including streaming ones. A CI/CD generation easily exceeds 100 seconds (LLM calls, tool execution, retries), so the signal would abort mid-stream, reader.read() would throw AbortError, and the backend mapped it to a 504 Gateway Timeout — killing the stream even though the agent was still working. Remove the timeout signal from agentFetch. The idle timeout in readAgentStream (300s between chunks) already handles hung connections. Apply the timeout only to cancelByRunId, which is a quick non-streaming call where a timeout is appropriate.
The agent emits an optional summary string in run.completed events. Add it to the RunCompletedData interface so the type system acknowledges it and it passes through the event proxy correctly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.