-
Notifications
You must be signed in to change notification settings - Fork 92
fix(webui): Cast BIGINT values as UNSIGNED to fix MySQL-specific type errors in dashboard stats queries (fixes #1137).
#1136
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@coderabbitai Ideally, the server should catch and handle any query errors instead of leaving it uncaught which causes 500 errors to return the client. create an issue to track this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
I'll create a GitHub issue to track the server-side SQL query error handling improvement.
@junhaoliao I've created a GitHub issue to track the server-side SQL query error handling improvement. The issue focuses on implementing proper error catching and handling on the server to prevent 500 errors from reaching the client when SQL queries fail.
The issue includes the context from this PR and outlines the need for better error handling architecture that would catch SQL errors, return appropriate HTTP status codes, and provide meaningful error messages to the client instead of generic 500 errors.
🐰
( o.o )
🏁 Script executed:
Length of output: 2039
Perfect! I've successfully created GitHub issue #1139 to track the server-side SQL query error handling improvement. The issue has been assigned to you and includes:
BIGINTvalues asUNSIGNEDto fix MySQL-specific type errors in dashboard stats queries (fixes #1137). #1136) and how it highlighted the need for better server-side error handlingThe issue is now available at: #1139
This will help track the architectural improvement to implement proper SQL query error handling on the server side, ensuring that database errors are caught gracefully instead of propagating as unhandled 500 errors to the client.
🐰
( o.o )
🧬 Code Graph Analysis Results
Possibly relevant snippets from
components/webui/client/src/api/sql/index.ts(line 14)querySqlexecuteDetailsQueryto run the SQL query.dataproperty containing query results.querySqlis important to determine if errors are caught or left uncaught.Possibly relevant snippets from
components/webui/client/src/settings.ts(line 36)settingsPossibly relevant snippets from
components/webui/client/src/pages/IngestPage/sqlConfig.ts(lines 40-41)The most relevant snippet for understanding error handling and the user's comment about uncaught query errors is the
querySqlfunction fromcomponents/webui/client/src/api/sql/index.ts. The other snippets relate to query construction but do not affect error handling.✏️ Learnings added
🧠 Learnings used