-
Notifications
You must be signed in to change notification settings - Fork 576
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
Return errors, not panic, when integers fail to parse in AUTO_INCREMENT
and TOP
#1305
Conversation
99cc39a
to
cd8a7d5
Compare
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.
Wow, this is a big problem, especially for people like me who use sqlparser inside a web server. @alamb, can we prioritize merging 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.
Looks good to me -- thank you @eejbyfeldt and @lovasoa
AUTO_INCREMENT
and TOP
Pull Request Test Coverage Report for Build 9454797383Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
There appears to be a CI failure on this PR: https://github.com/sqlparser-rs/sqlparser-rs/actions/runs/9454797383/job/26361666986?pr=1305 |
Fixed the issue. And enabled CI on my fork to catch these kind of issues earlier next time. |
Pull Request Test Coverage Report for Build 9565500013Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
Thanks again @eejbyfeldt |
This fixes several places where the code currently panic when parsing an integer value. This change makes us return the error instead.
This replaces #1304 by also handling one more cases and introducing a helper method that can be used in all places when an integer value needs to be parsed.
Closes #1303