Conversation
…mobile and extension Vendor dmmulroy/anti-slop (MIT) at tools/oxlint/anti-slop and enable seven of its rules for apps/mobile and apps/extension. Test files, test helpers, and extension scripts are exempt. zod-utils/no-inline-zod-schema needs type information, which oxlint JS plugins cannot access, so it runs through a minimal ESLint setup scoped to the same folders and wired into both lint scripts. Scope the global brace-expansion override to keep minimatch@3 (an ESLint dependency) on its compatible 1.x line.
…nd extension 543 violations across 215 files. Hand-rolled JSON and payload guards now parse with module-level zod schemas; typeof narrowing of already typed values uses non-typeof discriminants; wide Record and anonymous return-type annotations become satisfies or named types; unknown returns become generics or named domain types. Where the rule cannot be satisfied honestly (CDP-injected functions, generic payload walkers, ReactNode trees, environment probes), a scoped disable comment states the reason. Consolidate the duplicated tRPC error-code parser onto readTrpcErrorField in lib/trpc-error.ts.
The rule's type-aware check is optional — it falls back to syntactic detection when parserServices carries no program — but its getParserServices call throws before that branch when the tseslint node maps are missing, which they always are under oxlint. tools/oxlint/zod-utils.mjs wraps the rule and hands it a stub with program: null, so it runs as a plain oxlint jsPlugin. This removes eslint, typescript-eslint, eslint.config.mjs, the lint-script eslint steps, and the minimatch@3 brace-expansion override they needed.
iscekic
enabled auto-merge (squash)
August 19, 2026 16:11
pandemicsyn
approved these changes
Aug 19, 2026
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Executive SummaryReviewed the anti-slop/zod-utils lint enablement and 215-file violation fixes; remaining risk is pre-existing gateway Zod null handling, not introduced on commentable changed lines. Files Reviewed (215 files)
Reviewed by grok-4.6 · Input: 309.8K · Output: 24.2K · Cached: 1.5M Review guidance: REVIEW.md from base branch |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Enables seven anti-slop oxlint rules and zod-utils/no-inline-zod-schema for
apps/mobileandapps/extension, and fixes all 543 existing violations (215 files).Rules on:
no-chained-type-assertions,no-known-value-widening,no-object-parameters,no-reflect-apply,no-reflect-get,no-runtime-typeof,no-unknown-returns,zod-utils/no-inline-zod-schema. Test files, test helpers, andapps/extension/scriptsare exempt.How
tools/oxlint/anti-slop/and registered as ajsPluginsentry in both app oxlint configs. There is no real npm package;oxlint-plugin-anti-slopon npm is a name squat — do not install it.tools/oxlint/zod-utils.mjs. The rule's type-aware check is optional (it falls back to syntactic detection), but itsgetParserServicescall throws under oxlint before reaching that branch; the wrapper hands it a stubparserServiceswithprogram: null, which lands it on the syntactic path. No ESLint anywhere.Fix patterns
typeofon already-typed values → non-typeof narrowing (!== undefined,Array.isArray,in, discriminants).Record/anonymous annotations →satisfiesor named types.unknownreturns → generics or named domain types.readTrpcErrorFieldinlib/trpc-error.ts.Verification
apps/mobile: lint, typecheck,check:unusedclean; 4932/4932 tests pass.apps/extension: lint, typecheck clean; 1395/1395 tests pass.pnpm lintandpnpm typecheckclean.no-inline-zod-schemafires under both real app configs through the stub wrapper.