feat(builtins): add odoo_lint for Odoo modules #1671
All Vouch review confidence checks passed
Residual risk 0.16 = Change Risk (0.40) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.40 · 273 lines diff across 3 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.336
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #1671"
general
weight: 0.35
bosd
Adds an
odoo_lintbuiltin for odoo-lint (odl), a linter for Odoo modules written in Rust. It covers pylint-odoo's checks and OCA's translation (.po/.pot) checks, keeping their codes and messages, and runs as a single fast binary. Odoo projects can now lint and auto-fix their addons from hk:*/.py,*/.poand*/.pot. Projects are detected by a__manifest__.pyanywhere in the tree.check:odl check {{files}}.fix:odl check --fix {{files}}applies the safe fixes and exits non-zero while findings remain.check_diff:odl check --diffprints a unified diff of the fixes. Likeruff, it only covers fixable findings and exits 0 when there is nothing to fix, so the step chains a plainodl checkand setscheck_after_diff. Findings that can't be fixed then still fail.[tool.odoo-lint]inpyproject.toml, orodoo-lint.toml.Tests cover a clean and a failing check, fix, and diff. For the partial fixer they also cover diff and fix on a manifest with one fixable and one non-fixable finding. The tool stub installs
odoo-linterfrom PyPI.Validation:
hk test --step odoo_lintpasses all 7 tests locally, with hk built from this branch (Builtins.pkl generated with pkl 0.32.1) and odoo-linter 0.1.0a3, the version the tool stub pins.AI-assisted — Tool: Claude Code; model: anthropic/claude-opus-5-5; version: 2.1.294.
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
Summary by CodeRabbit
Tests
Added coverage for detecting Odoo modules with manifests at the project root or nested directories, while confirming that
setup.pyalone does not trigger detection.* Added a test stub for the
odoo-lintertool, version0.1.0a3.<!-- end of auto-generated comment: release notes by coderabbit.ai -->