Skip to content

ref: Set no-unused-vars eslint rule to error and clean up violations#1407

Merged
AbhiPrasad merged 1 commit intomainfrom
abhi-no-unused-vars-error
Feb 25, 2026
Merged

ref: Set no-unused-vars eslint rule to error and clean up violations#1407
AbhiPrasad merged 1 commit intomainfrom
abhi-no-unused-vars-error

Conversation

@AbhiPrasad
Copy link
Member

@AbhiPrasad AbhiPrasad commented Feb 25, 2026

resolves #1406

AI Summary

why this change is important:

The @typescript-eslint/no-unused-vars rule catches dead code — unused imports, variables, and type definitions that add noise, increase bundle size (for non-type imports), and make the codebase harder to maintain. Promoting it from "warn" to "error" means:

  1. It blocks CI — unused variables can no longer slip in unnoticed. Previously warnings were easy to ignore.
  2. Cleaner imports — many files were importing Zod runtime schemas (e.g., CodeBundleSchema, RepoInfoSchema) that were never used, only their TypeScript types were needed. These unused runtime imports could pull in unnecessary code.
  3. Removes dead code — things like serializeModel, SdkMcpToolDefinition, and HookEvent were defined but never referenced anywhere, creating confusion about whether they're part of the API surface.
  4. Prevents regressions — as an error, any future unused variable is caught at lint time rather than accumulating as tech debt.

@AbhiPrasad AbhiPrasad requested review from Qard and ibolmo February 25, 2026 22:51
@AbhiPrasad AbhiPrasad self-assigned this Feb 25, 2026
@AbhiPrasad AbhiPrasad force-pushed the abhi-no-unused-vars-error branch from c6abc27 to f958ba7 Compare February 25, 2026 22:56
@AbhiPrasad AbhiPrasad force-pushed the abhi-no-unused-vars-error branch from f958ba7 to 8c297a8 Compare February 25, 2026 23:02
@AbhiPrasad AbhiPrasad merged commit 4256279 into main Feb 25, 2026
37 checks passed
@AbhiPrasad AbhiPrasad deleted the abhi-no-unused-vars-error branch February 25, 2026 23:43
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.

Fix @typescript-eslint/no-unused-vars violations

2 participants