Repository navigation
chore(lint): fail CI on deprecated API usage - #1418
Merged
Merged
Conversation
Enables typescript/no-deprecated via oxlint --type-aware (oxlint-tsgolint). Generated client and files with existing deprecated usages are exempted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
📦 Bundle Size Report
Size Limits
Largest Files (Top 5)
View All Files (75 total)
✅ Bundle size check passed |
Contributor
|
Deploy preview for remote-flows ready!
Deployed with vercel-action |
Contributor
|
Deploy preview for adp-cost-calculator ready!
Deployed with vercel-action |
Only the generated client is exempted in config. The root type-aware run skips example/, which has its own lint step and whose deps aren't installed in the root lint job. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
📊 Coverage Report⚪ Coverage unchanged
Detailed BreakdownLines Coverage
Statements Coverage
Functions Coverage
Branches Coverage
✅ Coverage check passed |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jordividaller
approved these changes
Sep 29, 2026
Merged
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.
Summary
CI now fails when code uses an API marked
@deprecated, whether it's ours or from a dependency.Why
Editors don't always show deprecation strikethroughs reliably, so deprecated calls slip in unnoticed (e.g. TanStack's
isCancelledError, deprecated since@tanstack/query-core5.85.2, landed in #1415). A lint rule makes it deterministic.What changed
Toggle details
oxlint-tsgolint(dev) and switchednpm run linttooxlint --type-aware .—typescript/no-deprecatedneeds type information.typescript/no-deprecated: "error"in.oxlintrc.json.src/client/**viaoverrides— generated by openapi-ts, deprecations come from the gateway schema.// oxlint-disable-next-line typescript/no-deprecated(mostly our ownmutateAsync/*MutationAsync,Meta→NestedMeta,form_schema, plus RHFonChangeinTextField.tsxand a deprecated API field in PayrollAdminOnboarding). Line-level so new deprecated usages in those same files still fail; remove each disable when migrated.--ignore-pattern 'example/**': the root lint job doesn't installexample/deps, so type-aware linting there fails ontsconfig.e2e.json(@playwright/testnot found) and yields bogusanytypes.example/'s own lint script is nowoxlint --type-aware .(runs in Example App Checks, where the package is built and example deps are installed), withoxlint-tsgolintadded toexample/devDependencies. Its 5 existing hits (React 19 deprecatedReact.FormEvent) get per-line disables. Partners copy fromexample/, so it's the place deprecated APIs matter most.--type-awarealso turns on oxlint's default type-aware rules, adding ~45 warnings (no-floating-promises,await-thenable,restrict-template-expressions, …). Warnings don't fail CI; left visible rather than silenced.Screenshots
N/A
Related Resources
Testing
npm run lintpasses on this branch.isCancelledErrorfails withtypescript(no-deprecated).example/app in a browser — N/A🤖 Generated with Claude Code
Note
Low Risk
Tooling and lint-only changes with targeted disables; no production behavior or public API changes.
Overview
CI lint now fails on
@deprecatedAPI usage by enabling type-aware oxlint (oxlint --type-aware) withtypescript/no-deprecated: "error", backed by the newoxlint-tsgolintdev dependency.Root
npm run lintignoresexample/**(type-aware lint there runs via the example app’s own script). Generatedsrc/client/**is exempt via an oxlintrc override. Existing grandfathered hits (mostlymutationToPromise/mutateAsync,Meta, schema version helpers, RHFonChange, and exampleReact.FormEvent) get line-leveloxlint-disable-next-linecomments so new deprecated usage in those files still fails.Type-aware mode may surface additional oxlint warnings (e.g. floating promises); they do not fail CI. No public runtime API changes.
Reviewed by Cursor Bugbot for commit 74ddc7c. Bugbot is set up for automated code reviews on this repo. Configure here.