Does anyone know the Databricks-specific Python syntax highlight rules?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-08-2026 06:54 AM
The documentation on databricks.com says the following, in the context of configuring Python linting via pyproject.toml:
You can also disable Databricks-written syntax highlighting rules with a block such as:
[tool.databricks]
disabled_rules = ['DB01', 'DB03']
However, I have searched far and wide and I cannot find any documentation whatsoever that describes these rules. There have been some recent changes to error highlighting that I'd like to disable without entirely turning off error highlighting, but that's difficult without documentation (if it's even possible).
Does anyone know where to find information on this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-08-2026 08:49 PM
Hi — you're right that these Databricks-specific rule codes (DB01, DB03, etc.) are not documented anywhere publicly. The notebook editor docs only mention them as a configuration example without explaining what each rule checks.
What We Know
The DB* rules are Databricks-written diagnostics layered on top of the standard linters (Ruff, Pylint, Pyright, Flake8). They cover Databricks-specific patterns — things like PySpark API usage, dbutils calls, or notebook-specific syntax that standard linters wouldn't catch. But there's no public rule index like Ruff or Pylint provide.
How to Identify Which Rule Is Firing
When you see a highlighted error in the notebook editor, hover over the squiggly underline — the tooltip should show the rule code (e.g., DB01) and a short description. This is currently the only way to map a code to its meaning.
You can then selectively disable it:
# pyproject.toml (place in your notebook's ancestor path or ~/home)
[tool.databricks]
disabled_rules = ['DB01']
If You Want to Disable Broader Categories
You can also toggle the three highlighting categories independently via Settings → Developer:
- Python syntax error highlighting — core syntax errors (red)
- Python format error highlighting — formatting issues like line length (yellow/red, experimental)
- Python type error highlighting — type checking like missing args, wrong types (DBR 16.0+, experimental)
If the specific errors you want to suppress fall under formatting or type checking, toggling those off may be simpler than hunting individual rule codes.
Requesting Better Documentation
I'd suggest filing a docs feedback request via the "Was this page helpful?" widget on the notebook editor docs page — asking for a rule reference table would be a reasonable ask.
Docs:
Solutions Engineer @ Databricks