Skip to content

Change to sqruff from SQLFluff - #297

Merged
a5chin merged 5 commits into
developfrom
fix/sql
Aug 27, 2026
Merged

Change to sqruff from SQLFluff#297
a5chin merged 5 commits into
developfrom
fix/sql

Conversation

@a5chin

@a5chin a5chin commented Aug 26, 2026

Copy link
Copy Markdown
Owner

User description

Type of Change

  • Hotfix
  • Bug Fix
  • Dependency Update
  • Feature
  • Refactor
  • CI/CD
  • Documentation

Related Issues

Breaking Changes

  • No breaking changes
  • API signature changed
  • Configuration changed
  • Behavior changed
  • Dependencies changed
  • Features removed

Checklist

  • Dependencies added/updated
  • New environment variables
  • Performance impact assessed
  • Security implications reviewed
  • Deployment notes

Additional Context


PR Type

Refactoring, Configuration changes, Documentation


Description

  • Replace SQLFluff with sqruff across the project

  • Update Nox sessions for SQL formatting and linting

  • Configure VS Code, Zed, and pre-commit for sqruff

  • Refresh documentation and GitHub Actions workflows


Diagram Walkthrough

flowchart LR
  SQLFluff["SQLFluff (Old)"] -- "Replaced by" --> sqruff["sqruff (New)"]
  sqruff -- "Updates" --> Noxfile["noxfile.py"]
  sqruff -- "Updates" --> PreCommit["pre-commit-config.yaml"]
  sqruff -- "Updates" --> GitHubActions["GitHub Workflows"]
  sqruff -- "Updates" --> VSCodeConfig["VS Code Config"]
  sqruff -- "Updates" --> ZedConfig["Zed Config"]
  sqruff -- "Updates" --> Docs["Documentation"]
Loading

File Walkthrough

Relevant files
Refactoring
2 files
noxfile.py
Update Nox sessions to use `sqruff` for SQL formatting and linting.
+11/-11 
.pre-commit-config.yaml
Migrate pre-commit hooks from SQLFluff to sqruff and enhance
descriptions.
+30/-24 
Configuration changes
12 files
devcontainer.json
Replace SQLFluff VS Code extension with sqruff and configure its path.
+6/-2     
.dockerignore
Update ignored SQL linter configuration file.                       
+1/-1     
format.yml
Update GitHub Actions format workflow to use `sqruff`.     
+5/-4     
lint.yml
Update GitHub Actions lint workflow to use `sqruff`.         
+5/-4     
.sqlfluff
Remove `SQLFluff` configuration file.                                       
+0/-14   
.sqruff
Add `sqruff` configuration file.                                                 
+15/-0   
.sqruffignore
Adjust `sqruff` ignore patterns.                                                 
+0/-1     
cspell.json
Update spell checker dictionary for new tools.                     
+7/-1     
extensions.json
Replace `SQLFluff` VS Code extension with `sqruff`.           
+1/-1     
settings.json
Remove `SQLFluff` settings and configure `sqruff` as SQL formatter.
+2/-6     
settings.json
Configure Zed editor to use `sqruff` for SQL linting and formatting.
+2/-0     
codebook.toml
Update `codebook.toml` dictionary with new tool names.     
+4/-3     
Documentation
6 files
CLAUDE.md
Update `CLAUDE.md` documentation to reflect `sqruff` usage.
+12/-13 
index.md
Update documentation for SQL linter configuration.             
+7/-7     
pre-commit.md
Update pre-commit documentation for `sqruff` and hook descriptions.
+55/-21 
uv.md
Update uv documentation for sqruff VS Code extension and devcontainer
settings.
+9/-6     
index.md
Update development guides to reflect `sqruff` usage.         
+9/-9     
index.md
Update main documentation to reflect `sqruff` for SQL linting.
+3/-3     
Dependencies
1 files
pyproject.toml
Replace `sqlfluff` dependency with `sqruff` and add `regex`.
+2/-1     

@a5chin a5chin self-assigned this Aug 26, 2026
@a5chin a5chin added the enhancement New feature or request label Aug 26, 2026
@github-actions github-actions Bot added documentation Improvements or additions to documentation fix labels Aug 26, 2026
@codecov

codecov Bot commented Aug 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (88fba89) to head (2ac11ac).
✅ All tests successful. No failed tests found.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##           develop      #297   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            9         9           
  Lines          103       103           
  Branches         1         1           
=========================================
  Hits           103       103           
Flag Coverage Δ
unittests 100.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 88fba89...2ac11ac. Read the comment docs.

@a5chin

a5chin commented Aug 26, 2026

Copy link
Copy Markdown
Owner Author

/review

@github-actions

Copy link
Copy Markdown
Contributor

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 3 🔵🔵🔵⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Configuration Error

The sqruff-fix and sqruff-lint pre-commit hooks are configured with types: [python]. Since sqruff is a SQL linter/formatter, these hooks should apply to SQL files. This misconfiguration will prevent sqruff from running on SQL files during pre-commit checks.

Configuration Error

The sqruff-fix and sqruff-lint pre-commit hooks are configured with types: [python]. Since sqruff is a SQL linter/formatter, these hooks should apply to SQL files. This misconfiguration will prevent sqruff from running on SQL files during pre-commit checks.

Incorrect Ignore File

The .sqruffignore file appears to be a generic Python .gitignore file rather than a specific ignore file for sqruff. This might lead to sqruff either ignoring SQL files it should process or attempting to process files that should be ignored, potentially causing unexpected behavior or errors.

# General
.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon


# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
#  Usually these files are written by a python script from a template
#  before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.*cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/
pytest.xml
pytest-coverage.txt

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
#   For a library or package, you might want to ignore these files since the code is
#   intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
#   According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
#   However, in case of collaboration, if having platform-specific dependencies or dependencies
#   having no cross-platform support, pipenv may install dependencies that don't work, or not
#   install all needed dependencies.
#Pipfile.lock

# poetry
#   Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
#   This is especially recommended for binary packages to ensure reproducibility, and is more
#   commonly ignored for libraries.
#   https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
#   Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
#   pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
#   in version control.
#   https://pdm.fming.dev/latest/usage/project/#working-with-version-control
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
#  JetBrains specific template is maintained in a separate JetBrains.gitignore that can
#  be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
#  and can be added to the global gitignore or merged into this file.  For a more nuclear
#  option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/

# dbt
dbt_packages/
logs/
target/

@a5chin

a5chin commented Aug 26, 2026

Copy link
Copy Markdown
Owner Author

/improve

Comment thread noxfile.py
Comment thread .pre-commit-config.yaml
@a5chin
a5chin merged commit 601cc73 into develop Aug 27, 2026
18 checks passed
@a5chin
a5chin deleted the fix/sql branch August 27, 2026 01:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request fix Review effort 3/5

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant