-
Notifications
You must be signed in to change notification settings - Fork 77
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
failed to lex SQL query #81
Comments
Thanks for sharing this. Our SQL parser has had some difficulties with arrays so it may be related to that, or possibly the |
@wagenet Am I right, that if I want to turn off sql analysis, I should set my own list of probes without |
@andrey-lizunov if you'd like to silence the SQL parse error logging for now you can upgrade to 1.0.1 and set |
Here's another one:
|
@gkop thanks! I'm working on improving the lexer at this very moment :) |
any updates? |
@andriytyurnikov improving this requires rewriting much of our lexer. It's a project I'm actively working on as I have time for it. Unfortunately, I don't have an ETA yet. |
thanks, @wagenet |
@andriytyurnikov I believe one major goal is to filter out sensitive bits of the SQL before shipping it off to Skylight. |
@andriytyurnikov @gkop is correct. Furthermore, we do lots of aggregation based on similar queries which we're unable to do if we don't strip out variables. |
with all due respect to your effort - we already using new relic and getsentry to monitor our exceptions and performance, and I believe they not so carefull |
by the way - that particular SQL maybe was invalid (something like pg json operators applied to pg hash), but problem was with app exception that was not processed with Sentry (which may be more related to sentry itself)... I think I'll just mention cross-mention this issue in their repo |
@andriytyurnikov failure to parse isn't an exception. It doesn't stop application operation, it just means we can't report as much data to the Skylight servers. |
got another one (version 1.4.1)
|
I've made some good progress on the new SQL lexer. I still don't have an ETA, but wanted to let you all know that we're still working on it. |
Follow a log of queries to help:
|
@wagenet You could disable these errors in production. This is a kind of error that is important for Skylight, not for the people that is managing the rails app. |
@rhuanbarreto Thanks for sharing these! Given that most people only run Skylight in production, it was thought that if we wanted to gather information on failed queries, that would be the only place to do so. You can disable these warnings by setting |
For anyone still following along, I'm also fixing these parse failures in the new version of the SQL lexer. I expect a beta to be out in the coming weeks. |
So I've now got the new lexer successfully handling everything except for @rhuanbarreto's queries. @rhuanbarreto what SQL variant are you using? |
It's Microsoft SQL Server queries generated by tiny_tds gem together with free_tds driver for Linux. |
@wagenet you can use our public image on docker easysubsea/ruby-freetds:latest to have it running |
We have this error
failed to lex SQL query
for some SQL queries.Not sure why they occur and how to fix them.
You can find the query in the example below.
Database Postgresql 9.5, Rails 4.2.7, ruby 2.2.3p173, gem version 0.10.3
The text was updated successfully, but these errors were encountered: