-
-
Notifications
You must be signed in to change notification settings - Fork 33
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
Format Document
or SQLFluff: Fix
overwrites file contents with sqlfluff logs
#132
Comments
It looks like you are using the dbt templater here. Have you enabled the "sqlfluff.experimental.format.executeInTerminal": true, Take note of the
|
Regardless of settings a code formatter should never overwrite the contents of a file with log output right? This looks similar to #126 |
Ideally yes, however, the current implementation of this extension's default mode is to take the output from stdout and replace the content with that output. When using the dbt templater, dbt prints additional information to stdout which may be picked up from the formatter's output. The |
ok makes sense, thanks. that did fix the issue. should this just default to true for dbt templates? is that even possible? |
when running the extension from the command palette the contents of the file get overwritten with logs and no formatting is applied. this does not happen when running from the command line and in the below example no fixable violations are found.
installed sqlfluff version is 3.0.3
installed extension version is 3.0.0
example.mov
The text was updated successfully, but these errors were encountered: