You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains 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
HttpResponse error introduced by RPC is buggy since we are returning the exception as is instead of the string version of it.
Also RUNNING status on the graph execution is missing.
Changes 🏗️
Refactored & fixed the exception return handling on RPC failure.
Add RUNNING status update during the graph execution.
Checklist 📋
For code changes:
I have clearly listed my changes in the PR description
I have made a test plan
I have tested my changes according to the test plan:
...
Example test plan
Create from scratch and execute an agent with at least 3 blocks
Import an agent from file upload, and confirm it executes correctly
Upload agent to marketplace
Import an agent from marketplace and confirm it executes correctly
Edit an agent from monitor, and confirm it executes correctly
For configuration changes:
.env.example is updated or already compatible with my changes
docker-compose.yml is updated or already compatible with my changes
I have included a list of my configuration changes in the PR description (under Changes)
Examples of configuration changes
Changing ports
Adding new services that need to communicate with each other
Here are some key observations to aid the review process:
⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 No relevant tests
🔒 Security concerns
Error Information Exposure: The error handler returns the raw exception message to the client (line 250). This could potentially expose sensitive implementation details or stack traces. Consider sanitizing or limiting the error information sent to clients.
The new error handling approach removes try-catch blocks from endpoints but doesn't preserve the original error message context (function name). Consider if this context would be useful for debugging.
The error handler only explicitly handles ValueError (400) and generic Exception (500). Consider if other specific exception types need custom status codes.
majdyz
changed the title
fix(backend): Fix exception response on RPC error
fix(backend): Fix exception response on RPC error & Missing Graph Running Status
Feb 26, 2025
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.
HttpResponse error introduced by RPC is buggy since we are returning the exception as is instead of the string version of it.
Also
RUNNING
status on the graph execution is missing.Changes 🏗️
RUNNING
status update during the graph execution.Checklist 📋
For code changes:
Example test plan
For configuration changes:
.env.example
is updated or already compatible with my changesdocker-compose.yml
is updated or already compatible with my changesExamples of configuration changes