Skip to content

chore: adopt oxlint as the primary lint gate - #136

Merged
ElbertePlinio merged 2 commits into
mainfrom
chore/72-adopt-oxlint
Sep 9, 2026
Merged

ElbertePlinio merged 2 commits into
mainfrom
chore/72-adopt-oxlint

Conversation

@ElbertePlinio

Copy link
Copy Markdown
Member

Adopts oxlint 1.82.0 as the primary lint gate for the edit loop and CI. ESLint is removed: the previous eslint.config.mjs only enforced complexity (15), max-depth (4), and max-lines-per-function (100, skip blanks and comments; off in tests), and oxlint now enforces those equivalent rules with the same thresholds.

Closes #72

Baseline (oxlint 1.82.0 on this tree, before fixes)

The August 2025 audit expected about 12 findings. The current tree had 20 correctness findings before this change (plus 3 no-control-regex that are now disabled):

Rule Count Action
eslint/no-useless-escape 9 Fixed (cookie boundary regex; shell argv strings in CLI tests)
eslint/no-unsafe-optional-chaining 3 Fixed (MCP stdio conformance helpers)
eslint/no-control-regex 3 Disabled in .oxlintrc.json
unicorn/no-useless-fallback-in-spread 2 Fixed (...server.env, ...opts.extra)
unicorn/no-useless-spread 2 Fixed with Array.from(...) so iteration still snapshots before mutation
unicorn/prefer-string-starts-ends-with 1 Fixed (host.startsWith("127."))

no-control-regex stays off because those patterns exist to reject C0/DEL/bidi controls in AVD device names, android input text, and shell-unsafe path words. Matching control characters is the safety gate.

Suppressions

oxlint understands remaining eslint-disable-next-line comments. Session and evidence files that still carry Legacy gate debt: pickforge/pickforge#60 were converted to oxlint-disable-next-line with the same rules and scope, except one:

  • packages/desktop-linux/src/session.ts acquireSessionVncLock max-depth was paid instead of converted: extracting throwIfSessionGone dropped nesting from 5 to 4 so complexity-gate check --changed could pass on the touched function. The complexity disable on ensureSessionVnc remains, converted.

packages/browser/src/session.ts had no #60 comments on current main (two of the nine listed in #135 were already gone). Other #60 comments outside session/evidence files are left as eslint-disable-* for #135 to remove.

CI

The test job already ran bun run lint; that step is now named Lint and runs oxlint. This tree has no .complexity-gate.json, so complexity-gate was not added to CI.

Validation

On 5d0a3b1 in /home/dev/Projects/.worktrees/picklab/chore-72-oxlint:

README development commands do not name lint, so README was left unchanged.

Replace ESLint with oxlint 1.82.0 for the edit loop and CI, keeping the
same complexity, max-depth, and max-lines-per-function thresholds.
@ElbertePlinio
ElbertePlinio merged commit 277d5a8 into main Sep 9, 2026
10 checks passed
@ElbertePlinio
ElbertePlinio deleted the chore/72-adopt-oxlint branch September 9, 2026 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore: adopt oxlint as lint gate

1 participant