-
Notifications
You must be signed in to change notification settings - Fork 14k
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
fix: Trino - handle table not found in SQLLab #26355
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #26355 +/- ##
=======================================
Coverage 69.16% 69.16%
=======================================
Files 1948 1948
Lines 76054 76061 +7
Branches 8493 8493
=======================================
+ Hits 52601 52608 +7
Misses 21273 21273
Partials 2180 2180
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Thanks @Khrol for the PR. It seems—as in this example—that the expected behavior for the From a consistency standpoint it seems like the preferred fix would be to augment the |
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.
LGTM
Co-authored-by: John Bodley <4567245+john-bodley@users.noreply.github.com>
Co-authored-by: John Bodley <4567245+john-bodley@users.noreply.github.com> (cherry picked from commit 3daa038)
Co-authored-by: John Bodley <4567245+john-bodley@users.noreply.github.com>
Co-authored-by: John Bodley <4567245+john-bodley@users.noreply.github.com>
SUMMARY
SQLAlchemy doesn't strictly define what
get_indexes
method should do when table is not found.Some dialects return the empty list while some of them raise
NoSuchTableError
.When
NoSuchTableError
error is thrown, API returns 500 when non-existing table details are requested.This PR fixes this issue and returns 404 in such cases.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
Paste some non-existing table name in table name field and hit Enter:
Expected: no 500 errors from the backend.
ADDITIONAL INFORMATION