Skip to content

Clean up unused code and release packaging#134

Merged
AsafMah merged 1 commit into
mainfrom
maintenance/release-readiness-cleanup
Jul 12, 2026
Merged

Clean up unused code and release packaging#134
AsafMah merged 1 commit into
mainfrom
maintenance/release-readiness-cleanup

Conversation

@AsafMah

@AsafMah AsafMah commented Jul 12, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • reuse the shared, tested CF_HTML formatter for copied queries and remove the duplicate implementation flagged after Update dependencies and clean warning sources #133 merged
  • enable TypeScript unused-local and unused-parameter checks, then remove the dead state, helpers, parameters, imports, and redundant exports they exposed
  • remove redundant direct TypeScript ESLint dependencies while retaining the umbrella package used by the ESLint configuration
  • exclude integration-test inputs, saved query results, and generated VSIX files from release packages
  • avoid running the prepackage build twice when invoking npm run package

Validation

  • npm ci
  • npm audit
  • npm run type-check
  • npm run lint
  • npm test — 502 passed
  • npm run build-release-server
  • npm run test:integration — 46 passed
  • dotnet build src/Server/Server.csproj -c Release -warnaserror
  • dotnet run --project src/ServerTests/ServerTests.csproj -c Release — 200 passed
  • npm run package — packaged version 1.0.1 as a 114-file VSIX; verified tests, test configuration, .kqr, and nested .vsix files are absent

Notes

  • The package version was already bumped to 1.0.1; this PR does not change it.
  • The remaining Knip-reported integration files are glob/configuration entry points, and its remaining exported-type reports are types used by exported interface shapes rather than dead code.

Copilot AI review requested due to automatic review settings July 12, 2026 10:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR tightens TypeScript hygiene and reduces extension package contents by enabling unused-local/parameter checks, removing dead code and redundant dependencies they expose, reusing the shared CF_HTML clipboard formatter, and excluding development artifacts from VSIX packaging.

Changes:

  • Enabled noUnusedLocals / noUnusedParameters for both regular and integration TS builds, then removed or de-exported newly-detected unused members.
  • Reused the shared formatCfHtml helper for copied queries, eliminating the duplicated CF_HTML implementation.
  • Simplified packaging by relying on npm’s prepackage lifecycle (avoiding double builds) and excluding test inputs / .kqr / integration config from the VSIX.

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/Client/tsconfig.json Enables unused locals/parameters checks for the client TS build.
src/Client/tsconfig.integration.json Enables unused locals/parameters checks for integration TS build.
src/Client/package.json Avoids double-running prepackage when running npm run package; removes redundant TypeScript ESLint direct deps; formatting-only schema reflow.
src/Client/package-lock.json Removes lock entries for the removed direct TypeScript ESLint deps.
src/Client/features/server.ts Removes unused import and makes request param interfaces internal-only.
src/Client/features/resultsViewer.ts Removes unused exports/state and simplifies HTML builder call/signature.
src/Client/features/queryEditor.ts Reuses shared formatCfHtml for clipboard HTML copy; removes duplicated helper; marks unused params with _.
src/Client/features/plotlyChartProvider.ts Replaces magic string axis side with existing constant.
src/Client/features/copilot.ts Marks unused chat handler context param with _ for TS unused-parameter compliance.
src/Client/features/connectionsPanel.ts Marks unused parameters with _ for TS unused-parameter compliance.
src/Client/features/connectionManager.ts Makes storage key constants internal-only (no longer exported).
src/Client/.vscodeignore Excludes tests/integration inputs, .kqr, and related dev files from packaged VSIX.
Files not reviewed (1)
  • src/Client/package-lock.json: Generated file

@AsafMah AsafMah merged commit fae8b09 into main Jul 12, 2026
6 checks passed
@AsafMah AsafMah deleted the maintenance/release-readiness-cleanup branch July 12, 2026 11:01
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.

3 participants