sqlite: improve error reporting for prepared statements in SQLTagStore - #60227
Open
islandryu wants to merge 3 commits into
Open
sqlite: improve error reporting for prepared statements in SQLTagStore#60227islandryu wants to merge 3 commits into
islandryu wants to merge 3 commits into
Conversation
Collaborator
|
Review requested:
|
louwers
reviewed
Oct 12, 2025
|
|
||
| test('failed prepares throw', () => { | ||
| assert.throws(() => { | ||
| sql.all`SELECT * FROM does_not_exist`; // eslint-disable-line no-unused-expressions |
Contributor
There was a problem hiding this comment.
Consider configuring eslint with https://eslint.org/docs/latest/rules/no-unused-expressions#allowtaggedtemplates
Member
Author
There was a problem hiding this comment.
I have updated the ESLint configuration.
louwers
reviewed
Oct 12, 2025
louwers
reviewed
Oct 12, 2025
| message: 'Failed to prepare statement', | ||
| code: 'ERR_SQLITE_ERROR', | ||
| errcode: 1, | ||
| errstr: 'no such table: does_not_exist', |
Contributor
There was a problem hiding this comment.
Wrong way around I think, see other comment.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #60227 +/- ##
=======================================
Coverage 90.11% 90.11%
=======================================
Files 752 752
Lines 252200 252236 +36
Branches 47433 47447 +14
=======================================
+ Hits 227267 227309 +42
+ Misses 16239 16236 -3
+ Partials 8694 8691 -3
🚀 New features to boost your workflow:
|
Member
|
@islandryu Can you please rebase from main? |
Fixes: nodejs#60198 Signed-off-by: islandryu <shimaryuhei@gmail.com>
Signed-off-by: islandryu <shimaryuhei@gmail.com>
Signed-off-by: islandryu <shimaryuhei@gmail.com>
Member
|
The lint errors need to be fixed. |
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.
Fixes: #60198
I added report content for SQLTagStore.
Although the text in errstr differs from that of a conventional prepared statement, it now matches the corresponding SQLite function name.