Skip to content
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

SqlFluff RuntimeError Triggers Server Error 500 in Frontend #467

Closed
reata opened this issue Oct 16, 2023 · 0 comments · Fixed by #468
Closed

SqlFluff RuntimeError Triggers Server Error 500 in Frontend #467

reata opened this issue Oct 16, 2023 · 0 comments · Fixed by #468
Labels
bug Something isn't working

Comments

@reata
Copy link
Owner

reata commented Oct 16, 2023

Describe the bug

  • A clear and concise description of what the bug is.

SQL
Use trino dialect:

INSERT INTO xxx SELECT * FROM yyy;

As of sqlfluff 2.3.2, sqlfluff trino dialect doesn't support this yet. So it causes the following exception:

RuntimeError: Grammar refers to the 'Overwrite' keyword which was not found in the trino dialect.

The syntax in the query is not (yet?) supported. Try to narrow down your query to a minimal, reproducible case and raise an issue on GitHub.

Or, even better, see this guide on how to help contribute keyword and/or dialect updates:
https://github.com/sqlfluff/sqlfluff/wiki/Contributing-Dialect-Changes#keywords

To Reproduce

The web server returns 500 to frontend, and due to this is not in JSON format, frontend fails to parse it. It only shows:

Unexpected token 'A', "A server e"... is not valid JSON

Please check your SQL code for potential syntax error in Script View.

Expected behavior
Frontend to show the exact same error message as in backend.

Python version (available via python --version)

  • 3.8.17

SQLLineage version (available via sqllineage --version):

  • 1.4.7
@reata reata added the bug Something isn't working label Oct 16, 2023
@reata reata changed the title Server Error 500 Not Giving Meaningful Error Message to Frontend SqlFluff RuntimeError Triggers Server Error 500 in Frontend Oct 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant