Repository navigation
feat(route): legacy ladder and per-linter custom-rule counts - #577
Conversation
Adds the legacy-linter-recipes OpenSpec change and the customRules count detect reports for eslint, biome, pylint, flake8, and ruff.
route v7 checks for a rule the linter ships before anything else, gates a new custom rule on five of the repository's own, and renders a paragraph per linter detect found. create-legacy-rule v2 and onboard v7 follow it.
|
@claude /review |
|
Claude finished @theCodeDrift's task in 5m 47s —— View job Review completeReview mode: incremental — read 0 prior review thread(s) before reviewing.
SummaryThe implementation lines up well with the OpenSpec proposal/design/spec deltas: the Two inline findings, both [New]:
Nothing else stood out as incorrect — the ESLint "unknown" vs. counted-threshold logic, the Biome nested-config summation, the pylint |
…ing the scan Share the house rule-directory list between the custom-rule count and the scan's rule-style hints so the two cannot drift.
Both inline findings are fixed in ed49196: an unreadable ESLint rule directory is now skipped rather than failing — AI Coding Agent |
Stack (root → tip):
First of two PRs for the
legacy-linter-recipesOpenSpec change. For a linter the repository already runs, the agent now uses a rule that linter already ships instead of working out each tool's dialect from scratch. It writes a new custom rule there only when the repository's own rules give it something to copy.The legacy ladder.
route(topic v8) takes these in order:sgorvalerule.routeno longer asks the user to choose between a linter rule and a Taskless rule: the order decides. It also renders a paragraph for each linterdetectfound, saying what that tool always checks first.detect --jsonreportscustomRulesfor ESLint, Biome, pylint, flake8, and Ruff: a count of the rules the repository wrote itself for that linter, and where they are.pluginsentries.load-pluginsmodules that exist in the repository.[flake8:local-plugins]entries and published entry points.ESLint's count is
"unknown"when the config defines rules inline or imports a plugin from a local file, because counting those would mean running JavaScript. The recipes treat"unknown"as below the threshold.Recipes.
create-legacy-rulev3 looks for a shipped rule first and asks before adding a plugin the repository does not have. During onboarding (v11), the agent only enables rules from packages already installed: it writes no custom rules and adds no dependencies.Safe to merge on its own. The
routeparagraphs name onlycreate-legacy-rulehere; #578 adds--tool.Typecheck, lint, and the full test suite pass. The changeset is in this PR, and #578 extends it.