zedbee 0.1.0-beta.12 → 0.1.0-beta.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -2
- package/SECURITY.md +2 -0
- package/THIRD_PARTY_NOTICES.md +130 -14
- package/dist/attribution/entities.d.ts.map +1 -1
- package/dist/attribution/entities.js +74 -72
- package/dist/attribution/entities.js.map +1 -1
- package/dist/attribution/metrics.d.ts +2 -0
- package/dist/attribution/metrics.d.ts.map +1 -1
- package/dist/attribution/metrics.js +8 -0
- package/dist/attribution/metrics.js.map +1 -1
- package/dist/attribution/pair-locations.js +1 -1
- package/dist/attribution/pair-locations.js.map +1 -1
- package/dist/attribution/source-identity.d.ts +6 -0
- package/dist/attribution/source-identity.d.ts.map +1 -0
- package/dist/attribution/source-identity.js +60 -0
- package/dist/attribution/source-identity.js.map +1 -0
- package/dist/cache/key.d.ts +6 -1
- package/dist/cache/key.d.ts.map +1 -1
- package/dist/cache/key.js +57 -21
- package/dist/cache/key.js.map +1 -1
- package/dist/cache/store.d.ts.map +1 -1
- package/dist/cache/store.js +7 -7
- package/dist/cache/store.js.map +1 -1
- package/dist/checks/applicability.d.ts.map +1 -1
- package/dist/checks/applicability.js +17 -14
- package/dist/checks/applicability.js.map +1 -1
- package/dist/checks/complexity/adapter.d.ts.map +1 -1
- package/dist/checks/complexity/adapter.js +72 -18
- package/dist/checks/complexity/adapter.js.map +1 -1
- package/dist/checks/complexity/pair-class-metrics.d.ts +12 -0
- package/dist/checks/complexity/pair-class-metrics.d.ts.map +1 -0
- package/dist/checks/complexity/pair-class-metrics.js +220 -0
- package/dist/checks/complexity/pair-class-metrics.js.map +1 -0
- package/dist/checks/dead-code/adapter.d.ts.map +1 -1
- package/dist/checks/dead-code/adapter.js +8 -97
- package/dist/checks/dead-code/adapter.js.map +1 -1
- package/dist/checks/dead-code/framework-entrypoints.d.ts +9 -0
- package/dist/checks/dead-code/framework-entrypoints.d.ts.map +1 -0
- package/dist/checks/dead-code/framework-entrypoints.js +47 -0
- package/dist/checks/dead-code/framework-entrypoints.js.map +1 -0
- package/dist/checks/dead-code/import-boundary.d.ts +1 -1
- package/dist/checks/dead-code/import-boundary.d.ts.map +1 -1
- package/dist/checks/dead-code/import-boundary.js +3 -1
- package/dist/checks/dead-code/import-boundary.js.map +1 -1
- package/dist/checks/dead-code/knip-worker.js +19 -8
- package/dist/checks/dead-code/knip-worker.js.map +1 -1
- package/dist/checks/dead-code/managed-config.d.ts +4 -2
- package/dist/checks/dead-code/managed-config.d.ts.map +1 -1
- package/dist/checks/dead-code/managed-config.js +29 -2
- package/dist/checks/dead-code/managed-config.js.map +1 -1
- package/dist/checks/dead-code/parse-report.d.ts.map +1 -1
- package/dist/checks/dead-code/parse-report.js +26 -23
- package/dist/checks/dead-code/parse-report.js.map +1 -1
- package/dist/checks/dependency-architecture/adapter.d.ts.map +1 -1
- package/dist/checks/dependency-architecture/adapter.js +57 -46
- package/dist/checks/dependency-architecture/adapter.js.map +1 -1
- package/dist/checks/dependency-architecture/normalize-graph.d.ts +2 -0
- package/dist/checks/dependency-architecture/normalize-graph.d.ts.map +1 -1
- package/dist/checks/dependency-architecture/normalize-graph.js +12 -3
- package/dist/checks/dependency-architecture/normalize-graph.js.map +1 -1
- package/dist/checks/diagnostic-messages.d.ts +4 -0
- package/dist/checks/diagnostic-messages.d.ts.map +1 -0
- package/dist/checks/diagnostic-messages.js +50 -0
- package/dist/checks/diagnostic-messages.js.map +1 -0
- package/dist/checks/dispatch-adapter.d.ts +25 -0
- package/dist/checks/dispatch-adapter.d.ts.map +1 -0
- package/dist/checks/dispatch-adapter.js +133 -0
- package/dist/checks/dispatch-adapter.js.map +1 -0
- package/dist/checks/dispatch-cache.d.ts +9 -0
- package/dist/checks/dispatch-cache.d.ts.map +1 -0
- package/dist/checks/dispatch-cache.js +154 -0
- package/dist/checks/dispatch-cache.js.map +1 -0
- package/dist/checks/dispatch-context.d.ts +11 -0
- package/dist/checks/dispatch-context.d.ts.map +1 -0
- package/dist/checks/dispatch-context.js +155 -0
- package/dist/checks/dispatch-context.js.map +1 -0
- package/dist/checks/dispatch-target.d.ts +17 -0
- package/dist/checks/dispatch-target.d.ts.map +1 -0
- package/dist/checks/dispatch-target.js +167 -0
- package/dist/checks/dispatch-target.js.map +1 -0
- package/dist/checks/dispatcher.d.ts +3 -7
- package/dist/checks/dispatcher.d.ts.map +1 -1
- package/dist/checks/dispatcher.js +12 -642
- package/dist/checks/dispatcher.js.map +1 -1
- package/dist/checks/duplication/adapter.d.ts.map +1 -1
- package/dist/checks/duplication/adapter.js +44 -6
- package/dist/checks/duplication/adapter.js.map +1 -1
- package/dist/checks/duplication/clone-comparison.d.ts +6 -0
- package/dist/checks/duplication/clone-comparison.d.ts.map +1 -0
- package/dist/checks/duplication/clone-comparison.js +163 -0
- package/dist/checks/duplication/clone-comparison.js.map +1 -0
- package/dist/checks/duplication/normalize-clone.d.ts.map +1 -1
- package/dist/checks/duplication/normalize-clone.js +9 -0
- package/dist/checks/duplication/normalize-clone.js.map +1 -1
- package/dist/checks/duplication/source-tokens.d.ts +18 -0
- package/dist/checks/duplication/source-tokens.d.ts.map +1 -0
- package/dist/checks/duplication/source-tokens.js +68 -0
- package/dist/checks/duplication/source-tokens.js.map +1 -0
- package/dist/checks/duplication/types.d.ts +2 -0
- package/dist/checks/duplication/types.d.ts.map +1 -1
- package/dist/checks/engine-identity.d.ts.map +1 -1
- package/dist/checks/engine-identity.js +9 -8
- package/dist/checks/engine-identity.js.map +1 -1
- package/dist/checks/eslint/convert-message.d.ts +2 -0
- package/dist/checks/eslint/convert-message.d.ts.map +1 -1
- package/dist/checks/eslint/convert-message.js +34 -1
- package/dist/checks/eslint/convert-message.js.map +1 -1
- package/dist/checks/eslint/lint-adapter.d.ts.map +1 -1
- package/dist/checks/eslint/lint-adapter.js +17 -13
- package/dist/checks/eslint/lint-adapter.js.map +1 -1
- package/dist/checks/events.d.ts +7 -1
- package/dist/checks/events.d.ts.map +1 -1
- package/dist/checks/metadata.d.ts +4 -2
- package/dist/checks/metadata.d.ts.map +1 -1
- package/dist/checks/metadata.js +7 -4
- package/dist/checks/metadata.js.map +1 -1
- package/dist/checks/observation-result.d.ts.map +1 -1
- package/dist/checks/observation-result.js +26 -14
- package/dist/checks/observation-result.js.map +1 -1
- package/dist/checks/prettier/project-engine.d.ts +8 -14
- package/dist/checks/prettier/project-engine.d.ts.map +1 -1
- package/dist/checks/prettier/project-engine.js +33 -281
- package/dist/checks/prettier/project-engine.js.map +1 -1
- package/dist/checks/prettier/project-error.d.ts +7 -0
- package/dist/checks/prettier/project-error.d.ts.map +1 -0
- package/dist/checks/prettier/project-error.js +12 -0
- package/dist/checks/prettier/project-error.js.map +1 -0
- package/dist/checks/prettier/project-import-capture.d.ts +20 -0
- package/dist/checks/prettier/project-import-capture.d.ts.map +1 -0
- package/dist/checks/prettier/project-import-capture.js +173 -0
- package/dist/checks/prettier/project-import-capture.js.map +1 -0
- package/dist/checks/prettier/project-import-dependencies.d.ts +5 -0
- package/dist/checks/prettier/project-import-dependencies.d.ts.map +1 -0
- package/dist/checks/prettier/project-import-dependencies.js +84 -0
- package/dist/checks/prettier/project-import-dependencies.js.map +1 -0
- package/dist/checks/prettier/project-installation.d.ts +3 -0
- package/dist/checks/prettier/project-installation.d.ts.map +1 -0
- package/dist/checks/prettier/project-installation.js +204 -0
- package/dist/checks/prettier/project-installation.js.map +1 -0
- package/dist/checks/prettier/project-protocol.d.ts.map +1 -1
- package/dist/checks/prettier/project-protocol.js +15 -3
- package/dist/checks/prettier/project-protocol.js.map +1 -1
- package/dist/checks/prettier/project-snapshot-identity.d.ts +7 -0
- package/dist/checks/prettier/project-snapshot-identity.d.ts.map +1 -0
- package/dist/checks/prettier/project-snapshot-identity.js +63 -0
- package/dist/checks/prettier/project-snapshot-identity.js.map +1 -0
- package/dist/checks/prettier/project-types.d.ts +2 -0
- package/dist/checks/prettier/project-types.d.ts.map +1 -1
- package/dist/checks/prettier/project-worker.js +25 -3
- package/dist/checks/prettier/project-worker.js.map +1 -1
- package/dist/checks/prettier/project-workspace.d.ts +7 -0
- package/dist/checks/prettier/project-workspace.d.ts.map +1 -1
- package/dist/checks/prettier/project-workspace.js +101 -40
- package/dist/checks/prettier/project-workspace.js.map +1 -1
- package/dist/checks/project-inputs.d.ts +6 -0
- package/dist/checks/project-inputs.d.ts.map +1 -0
- package/dist/checks/project-inputs.js +70 -0
- package/dist/checks/project-inputs.js.map +1 -0
- package/dist/checks/runner/process-group.d.ts.map +1 -1
- package/dist/checks/runner/process-group.js +30 -2
- package/dist/checks/runner/process-group.js.map +1 -1
- package/dist/checks/secrets/content.d.ts.map +1 -1
- package/dist/checks/secrets/content.js +35 -16
- package/dist/checks/secrets/content.js.map +1 -1
- package/dist/checks/typescript/adapter.d.ts.map +1 -1
- package/dist/checks/typescript/adapter.js +6 -14
- package/dist/checks/typescript/adapter.js.map +1 -1
- package/dist/checks/typescript/aliases.d.ts +28 -0
- package/dist/checks/typescript/aliases.d.ts.map +1 -0
- package/dist/checks/typescript/aliases.js +259 -0
- package/dist/checks/typescript/aliases.js.map +1 -0
- package/dist/checks/typescript/configuration-paths.d.ts +8 -0
- package/dist/checks/typescript/configuration-paths.d.ts.map +1 -0
- package/dist/checks/typescript/configuration-paths.js +138 -0
- package/dist/checks/typescript/configuration-paths.js.map +1 -0
- package/dist/checks/typescript/convert-diagnostic.d.ts +2 -0
- package/dist/checks/typescript/convert-diagnostic.d.ts.map +1 -1
- package/dist/checks/typescript/convert-diagnostic.js +23 -5
- package/dist/checks/typescript/convert-diagnostic.js.map +1 -1
- package/dist/checks/typescript/project-coverage.d.ts +16 -0
- package/dist/checks/typescript/project-coverage.d.ts.map +1 -0
- package/dist/checks/typescript/project-coverage.js +49 -0
- package/dist/checks/typescript/project-coverage.js.map +1 -0
- package/dist/checks/vulnerabilities/inventory/normalize.d.ts +1 -0
- package/dist/checks/vulnerabilities/inventory/normalize.d.ts.map +1 -1
- package/dist/checks/vulnerabilities/inventory/normalize.js +5 -2
- package/dist/checks/vulnerabilities/inventory/normalize.js.map +1 -1
- package/dist/checks/vulnerabilities/inventory/parse-bun.d.ts.map +1 -1
- package/dist/checks/vulnerabilities/inventory/parse-bun.js +18 -7
- package/dist/checks/vulnerabilities/inventory/parse-bun.js.map +1 -1
- package/dist/checks/vulnerabilities/inventory/parse-yarn.d.ts.map +1 -1
- package/dist/checks/vulnerabilities/inventory/parse-yarn.js +21 -11
- package/dist/checks/vulnerabilities/inventory/parse-yarn.js.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +3 -0
- package/dist/cli.js.map +1 -1
- package/dist/commands/agent.js +1 -1
- package/dist/commands/agent.js.map +1 -1
- package/dist/commands/checks.d.ts +5 -2
- package/dist/commands/checks.d.ts.map +1 -1
- package/dist/commands/checks.js +18 -5
- package/dist/commands/checks.js.map +1 -1
- package/dist/commands/fix.d.ts.map +1 -1
- package/dist/commands/fix.js +6 -297
- package/dist/commands/fix.js.map +1 -1
- package/dist/commands/init.d.ts +4 -2
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +36 -379
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/scan.d.ts +2 -1
- package/dist/commands/scan.d.ts.map +1 -1
- package/dist/commands/scan.js +6 -13
- package/dist/commands/scan.js.map +1 -1
- package/dist/commands/telemetry.d.ts.map +1 -1
- package/dist/commands/telemetry.js +3 -0
- package/dist/commands/telemetry.js.map +1 -1
- package/dist/config/load-config.d.ts.map +1 -1
- package/dist/config/load-config.js +6 -15
- package/dist/config/load-config.js.map +1 -1
- package/dist/config/selection-path.d.ts +7 -0
- package/dist/config/selection-path.d.ts.map +1 -0
- package/dist/config/selection-path.js +20 -0
- package/dist/config/selection-path.js.map +1 -0
- package/dist/core/check-label.d.ts +2 -0
- package/dist/core/check-label.d.ts.map +1 -0
- package/dist/core/check-label.js +19 -0
- package/dist/core/check-label.js.map +1 -0
- package/dist/core/freeze-result.d.ts +3 -0
- package/dist/core/freeze-result.d.ts.map +1 -0
- package/dist/core/freeze-result.js +10 -0
- package/dist/core/freeze-result.js.map +1 -0
- package/dist/core/immutable-map.d.ts +3 -0
- package/dist/core/immutable-map.d.ts.map +1 -0
- package/dist/core/immutable-map.js +33 -0
- package/dist/core/immutable-map.js.map +1 -0
- package/dist/core/kernel-lease.d.ts +17 -0
- package/dist/core/kernel-lease.d.ts.map +1 -0
- package/dist/core/kernel-lease.js +55 -0
- package/dist/core/kernel-lease.js.map +1 -0
- package/dist/fixes/apply-plan.d.ts.map +1 -1
- package/dist/fixes/apply-plan.js +2 -9
- package/dist/fixes/apply-plan.js.map +1 -1
- package/dist/fixes/build-plan.d.ts +5 -5
- package/dist/fixes/build-plan.d.ts.map +1 -1
- package/dist/fixes/build-plan.js +15 -466
- package/dist/fixes/build-plan.js.map +1 -1
- package/dist/fixes/exact-edits.d.ts +11 -1
- package/dist/fixes/exact-edits.d.ts.map +1 -1
- package/dist/fixes/exact-edits.js +101 -46
- package/dist/fixes/exact-edits.js.map +1 -1
- package/dist/fixes/plan-candidates.d.ts +8 -0
- package/dist/fixes/plan-candidates.d.ts.map +1 -0
- package/dist/fixes/plan-candidates.js +144 -0
- package/dist/fixes/plan-candidates.js.map +1 -0
- package/dist/fixes/prettier-provider.d.ts +3 -2
- package/dist/fixes/prettier-provider.d.ts.map +1 -1
- package/dist/fixes/prettier-provider.js +53 -0
- package/dist/fixes/prettier-provider.js.map +1 -1
- package/dist/fixes/public-plan.d.ts +8 -0
- package/dist/fixes/public-plan.d.ts.map +1 -0
- package/dist/fixes/public-plan.js +194 -0
- package/dist/fixes/public-plan.js.map +1 -0
- package/dist/fixes/working-preview.d.ts +18 -0
- package/dist/fixes/working-preview.d.ts.map +1 -0
- package/dist/fixes/working-preview.js +162 -0
- package/dist/fixes/working-preview.js.map +1 -0
- package/dist/git/change-set.d.ts.map +1 -1
- package/dist/git/change-set.js +10 -9
- package/dist/git/change-set.js.map +1 -1
- package/dist/git/client.d.ts +16 -0
- package/dist/git/client.d.ts.map +1 -1
- package/dist/git/client.js +46 -3
- package/dist/git/client.js.map +1 -1
- package/dist/git/merge-comparison.d.ts.map +1 -1
- package/dist/git/merge-comparison.js +16 -4
- package/dist/git/merge-comparison.js.map +1 -1
- package/dist/git/selected-comparison.d.ts +13 -0
- package/dist/git/selected-comparison.d.ts.map +1 -0
- package/dist/git/selected-comparison.js +143 -0
- package/dist/git/selected-comparison.js.map +1 -0
- package/dist/git/snapshot-work.d.ts +18 -0
- package/dist/git/snapshot-work.d.ts.map +1 -0
- package/dist/git/snapshot-work.js +59 -0
- package/dist/git/snapshot-work.js.map +1 -0
- package/dist/git/snapshot.d.ts +6 -1
- package/dist/git/snapshot.d.ts.map +1 -1
- package/dist/git/snapshot.js +102 -5
- package/dist/git/snapshot.js.map +1 -1
- package/dist/init/formatter-setup.d.ts +29 -0
- package/dist/init/formatter-setup.d.ts.map +1 -0
- package/dist/init/formatter-setup.js +166 -0
- package/dist/init/formatter-setup.js.map +1 -0
- package/dist/init/import-provenance.d.ts +7 -0
- package/dist/init/import-provenance.d.ts.map +1 -0
- package/dist/init/import-provenance.js +58 -0
- package/dist/init/import-provenance.js.map +1 -0
- package/dist/init/install-dependency.d.mts +40 -0
- package/dist/init/install-dependency.mjs +427 -0
- package/dist/init/install-project.d.ts +1 -0
- package/dist/init/install-project.d.ts.map +1 -1
- package/dist/init/install-project.js +12 -31
- package/dist/init/install-project.js.map +1 -1
- package/dist/init/presentation.d.ts +54 -0
- package/dist/init/presentation.d.ts.map +1 -0
- package/dist/init/presentation.js +139 -0
- package/dist/init/presentation.js.map +1 -0
- package/dist/init/selection-policy.d.ts +29 -0
- package/dist/init/selection-policy.d.ts.map +1 -0
- package/dist/init/selection-policy.js +59 -0
- package/dist/init/selection-policy.js.map +1 -0
- package/dist/init/types.d.ts +7 -0
- package/dist/init/types.d.ts.map +1 -1
- package/dist/init/types.js.map +1 -1
- package/dist/init/write-config.d.ts.map +1 -1
- package/dist/init/write-config.js +3 -13
- package/dist/init/write-config.js.map +1 -1
- package/dist/inspection/inspect-repository.d.ts.map +1 -1
- package/dist/inspection/inspect-repository.js +17 -3
- package/dist/inspection/inspect-repository.js.map +1 -1
- package/dist/inspection/snapshot-registry.d.ts +2 -0
- package/dist/inspection/snapshot-registry.d.ts.map +1 -1
- package/dist/inspection/snapshot-registry.js +58 -7
- package/dist/inspection/snapshot-registry.js.map +1 -1
- package/dist/inspection/types.d.ts +6 -1
- package/dist/inspection/types.d.ts.map +1 -1
- package/dist/inspection/types.js +7 -1
- package/dist/inspection/types.js.map +1 -1
- package/dist/inspection/workspaces.d.ts.map +1 -1
- package/dist/inspection/workspaces.js +17 -0
- package/dist/inspection/workspaces.js.map +1 -1
- package/dist/reporting/check-label.d.ts +1 -1
- package/dist/reporting/check-label.d.ts.map +1 -1
- package/dist/reporting/check-label.js +1 -18
- package/dist/reporting/check-label.js.map +1 -1
- package/dist/reporting/fix-plan-store.d.ts +7 -0
- package/dist/reporting/fix-plan-store.d.ts.map +1 -0
- package/dist/reporting/fix-plan-store.js +29 -0
- package/dist/reporting/fix-plan-store.js.map +1 -0
- package/dist/reporting/fix-presentation.d.ts +77 -0
- package/dist/reporting/fix-presentation.d.ts.map +1 -0
- package/dist/reporting/fix-presentation.js +262 -0
- package/dist/reporting/fix-presentation.js.map +1 -0
- package/dist/reporting/temporary-report-common.d.ts +27 -0
- package/dist/reporting/temporary-report-common.d.ts.map +1 -0
- package/dist/reporting/temporary-report-common.js +33 -0
- package/dist/reporting/temporary-report-common.js.map +1 -0
- package/dist/reporting/temporary-report-filesystem.d.ts +6 -0
- package/dist/reporting/temporary-report-filesystem.d.ts.map +1 -0
- package/dist/reporting/temporary-report-filesystem.js +124 -0
- package/dist/reporting/temporary-report-filesystem.js.map +1 -0
- package/dist/reporting/temporary-report-lifecycle.d.ts +19 -0
- package/dist/reporting/temporary-report-lifecycle.d.ts.map +1 -0
- package/dist/reporting/temporary-report-lifecycle.js +278 -0
- package/dist/reporting/temporary-report-lifecycle.js.map +1 -0
- package/dist/reporting/temporary-report-lock.d.ts +21 -0
- package/dist/reporting/temporary-report-lock.d.ts.map +1 -0
- package/dist/reporting/temporary-report-lock.js +106 -0
- package/dist/reporting/temporary-report-lock.js.map +1 -0
- package/dist/reporting/temporary-reports.d.ts +3 -24
- package/dist/reporting/temporary-reports.d.ts.map +1 -1
- package/dist/reporting/temporary-reports.js +10 -534
- package/dist/reporting/temporary-reports.js.map +1 -1
- package/dist/scan/analysis-failure.d.ts.map +1 -1
- package/dist/scan/analysis-failure.js +23 -0
- package/dist/scan/analysis-failure.js.map +1 -1
- package/dist/scan/analysis-session.d.ts +4 -0
- package/dist/scan/analysis-session.d.ts.map +1 -1
- package/dist/scan/analysis-session.js +60 -13
- package/dist/scan/analysis-session.js.map +1 -1
- package/dist/scan/incomplete-report.js +2 -2
- package/dist/scan/incomplete-report.js.map +1 -1
- package/dist/scan/merge-scan.d.ts +2 -1
- package/dist/scan/merge-scan.d.ts.map +1 -1
- package/dist/scan/merge-scan.js +82 -37
- package/dist/scan/merge-scan.js.map +1 -1
- package/dist/scan/progress.d.ts +4 -0
- package/dist/scan/progress.d.ts.map +1 -0
- package/dist/scan/progress.js +18 -0
- package/dist/scan/progress.js.map +1 -0
- package/dist/scan/run-scan.d.ts.map +1 -1
- package/dist/scan/run-scan.js +11 -15
- package/dist/scan/run-scan.js.map +1 -1
- package/dist/scan/source-excerpts.d.ts +1 -1
- package/dist/scan/source-excerpts.d.ts.map +1 -1
- package/dist/scan/source-excerpts.js +25 -27
- package/dist/scan/source-excerpts.js.map +1 -1
- package/dist/service/client-connection.d.ts +21 -0
- package/dist/service/client-connection.d.ts.map +1 -0
- package/dist/service/client-connection.js +219 -0
- package/dist/service/client-connection.js.map +1 -0
- package/dist/service/client-executor.d.ts +10 -0
- package/dist/service/client-executor.d.ts.map +1 -0
- package/dist/service/client-executor.js +69 -0
- package/dist/service/client-executor.js.map +1 -0
- package/dist/service/client-ownership.d.ts +16 -0
- package/dist/service/client-ownership.d.ts.map +1 -0
- package/dist/service/client-ownership.js +104 -0
- package/dist/service/client-ownership.js.map +1 -0
- package/dist/service/client-startup.d.ts +3 -0
- package/dist/service/client-startup.d.ts.map +1 -0
- package/dist/service/client-startup.js +123 -0
- package/dist/service/client-startup.js.map +1 -0
- package/dist/service/client.d.ts +2 -27
- package/dist/service/client.d.ts.map +1 -1
- package/dist/service/client.js +7 -490
- package/dist/service/client.js.map +1 -1
- package/dist/service/identity-parallel.js +3 -3
- package/dist/service/identity-parallel.js.map +1 -1
- package/dist/service/identity.js +4 -4
- package/dist/service/identity.js.map +1 -1
- package/dist/service/server-connection.d.ts +43 -0
- package/dist/service/server-connection.d.ts.map +1 -0
- package/dist/service/server-connection.js +327 -0
- package/dist/service/server-connection.js.map +1 -0
- package/dist/service/server.d.ts +1 -1
- package/dist/service/server.d.ts.map +1 -1
- package/dist/service/server.js +77 -343
- package/dist/service/server.js.map +1 -1
- package/dist/service/state.d.ts.map +1 -1
- package/dist/service/state.js +14 -26
- package/dist/service/state.js.map +1 -1
- package/dist/service/windows-pipe.d.ts +22 -14
- package/dist/service/windows-pipe.d.ts.map +1 -1
- package/dist/service/windows-pipe.js +384 -350
- package/dist/service/windows-pipe.js.map +1 -1
- package/dist/telemetry/ai-context.d.ts +14 -0
- package/dist/telemetry/ai-context.d.ts.map +1 -0
- package/dist/telemetry/ai-context.js +129 -0
- package/dist/telemetry/ai-context.js.map +1 -0
- package/dist/telemetry/batch.d.ts +4 -0
- package/dist/telemetry/batch.d.ts.map +1 -0
- package/dist/telemetry/batch.js +21 -0
- package/dist/telemetry/batch.js.map +1 -0
- package/dist/telemetry/client.d.ts +3 -0
- package/dist/telemetry/client.d.ts.map +1 -1
- package/dist/telemetry/client.js +63 -2
- package/dist/telemetry/client.js.map +1 -1
- package/dist/telemetry/details-store.d.ts +15 -0
- package/dist/telemetry/details-store.d.ts.map +1 -0
- package/dist/telemetry/details-store.js +198 -0
- package/dist/telemetry/details-store.js.map +1 -0
- package/dist/telemetry/finding-catalog.d.ts +2 -0
- package/dist/telemetry/finding-catalog.d.ts.map +1 -0
- package/dist/telemetry/finding-catalog.js +2817 -0
- package/dist/telemetry/finding-catalog.js.map +1 -0
- package/dist/telemetry/finding-rules.d.ts +3 -0
- package/dist/telemetry/finding-rules.d.ts.map +1 -0
- package/dist/telemetry/finding-rules.js +16 -0
- package/dist/telemetry/finding-rules.js.map +1 -0
- package/dist/telemetry/finding-summary.d.ts +8 -0
- package/dist/telemetry/finding-summary.d.ts.map +1 -0
- package/dist/telemetry/finding-summary.js +63 -0
- package/dist/telemetry/finding-summary.js.map +1 -0
- package/dist/telemetry/schema.d.ts +603 -4
- package/dist/telemetry/schema.d.ts.map +1 -1
- package/dist/telemetry/schema.js +117 -1
- package/dist/telemetry/schema.js.map +1 -1
- package/dist/telemetry/state.d.ts +5 -4
- package/dist/telemetry/state.d.ts.map +1 -1
- package/dist/telemetry/state.js +115 -69
- package/dist/telemetry/state.js.map +1 -1
- package/dist/telemetry/transport.d.ts.map +1 -1
- package/dist/telemetry/transport.js +5 -1
- package/dist/telemetry/transport.js.map +1 -1
- package/dist/telemetry/worker.d.ts.map +1 -1
- package/dist/telemetry/worker.js +9 -1
- package/dist/telemetry/worker.js.map +1 -1
- package/dist/ui/init-app.d.ts +6 -14
- package/dist/ui/init-app.d.ts.map +1 -1
- package/dist/ui/init-app.js +39 -203
- package/dist/ui/init-app.js.map +1 -1
- package/dist/ui/init-operation.d.ts +19 -0
- package/dist/ui/init-operation.d.ts.map +1 -0
- package/dist/ui/init-operation.js +54 -0
- package/dist/ui/init-operation.js.map +1 -0
- package/dist/ui/init-view.d.ts +42 -0
- package/dist/ui/init-view.d.ts.map +1 -0
- package/dist/ui/init-view.js +199 -0
- package/dist/ui/init-view.js.map +1 -0
- package/dist/ui/live-dashboard.d.ts +5 -1
- package/dist/ui/live-dashboard.d.ts.map +1 -1
- package/dist/ui/live-dashboard.js +46 -4
- package/dist/ui/live-dashboard.js.map +1 -1
- package/dist/vendor/knip/node_modules/get-tsconfig/LICENSE +21 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/README.md +268 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/dist/index.cjs +7 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/dist/index.d.cts +2116 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/dist/index.d.mts +2116 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/dist/index.mjs +7 -0
- package/dist/vendor/knip/node_modules/get-tsconfig/package.json +46 -0
- package/docs/checks.md +56 -5
- package/docs/cli-reference.md +12 -2
- package/docs/commercial-licensing.md +1 -1
- package/docs/managed-fixes.md +14 -0
- package/docs/privacy.md +55 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslint-recommended-raw.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/all.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/all.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/base.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/disable-type-checked.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/disable-type-checked.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/eslint-recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked-only.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked-only.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/all.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/base.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/disable-type-checked.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/eslint-recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked-only.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/index.d.ts +9 -447
- package/node_modules/@typescript-eslint/eslint-plugin/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/raw-plugin.d.ts +9 -447
- package/node_modules/@typescript-eslint/eslint-plugin/dist/raw-plugin.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/adjacent-overload-signatures.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/array-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/await-thenable.d.ts +6 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/await-thenable.js +41 -6
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/ban-ts-comment.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/ban-tslint-comment.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/class-literal-property-style.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/class-methods-use-this.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-generic-constructors.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-indexed-object-style.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-return.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-assertions.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-definitions.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-exports.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-imports.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/default-param-last.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/dot-notation.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/enum-utils/shared.d.ts +9 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/enum-utils/shared.js +69 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-function-return-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-member-accessibility.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-module-boundary-types.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/index.d.ts +1 -447
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/index.js +141 -273
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/init-declarations.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/max-params.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/member-ordering.js +59 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/method-signature-style.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/enums.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/format.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/parse-options.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/schema.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/shared.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/validator.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-array-constructor.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-array-delete.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-base-to-string.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-confusing-non-null-assertion.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-confusing-void-expression.js +30 -10
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-deprecated.js +57 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-dupe-class-members.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-duplicate-enum-values.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-duplicate-type-constituents.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-dynamic-delete.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-function.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-interface.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-object-type.js +10 -4
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-explicit-any.js +12 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-extra-non-null-assertion.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-extraneous-class.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-floating-promises.js +65 -55
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-for-in-array.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-generated-empty-object-type.d.ts +4 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-generated-empty-object-type.js +97 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-implied-eval.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-import-type-side-effects.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-inferrable-types.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-invalid-this.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-invalid-void-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-loop-func.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-loss-of-precision.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-magic-numbers.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-meaningless-void-operator.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-meaningless-void-operator.js +49 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-new.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-promises.d.ts +5 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-promises.js +76 -4
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-spread.js +6 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-mixed-enums.js +35 -23
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-namespace.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-asserted-nullish-coalescing.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-asserted-optional-chain.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-assertion.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-redeclare.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-redundant-type-constituents.js +6 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-require-imports.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-restricted-imports.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-restricted-types.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-shadow.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-this-alias.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-type-alias.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-boolean-literal-compare.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-condition.js +85 -12
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-parameter-property-assignment.js +14 -4
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-qualifier.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-template-expression.js +4 -14
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-arguments.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-assertion.d.ts +2 -3
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-assertion.js +52 -49
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-constraint.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-conversion.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-parameters.js +46 -18
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-argument.js +3 -91
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-assignment.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-call.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-declaration-merging.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-enum-assignment.d.ts +5 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-enum-assignment.js +518 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-enum-comparison.js +4 -113
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-function-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-member-access.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-return.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-type-assertion.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-unary-minus.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-expressions.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-private-class-members.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-vars.js +6 -5
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-use-before-define.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-constructor.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-default-assignment.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-default-assignment.js +29 -7
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-empty-export.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-var-requires.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-wrapper-object-types.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/non-nullable-type-assertion-style.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/only-throw-error.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/parameter-properties.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-as-const.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-destructuring.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-enum-initializers.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-find.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-for-of.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-function-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-includes.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-literal-enum-member.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-namespace-keyword.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-nullish-coalescing.js +4 -3
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/PreferOptionalChainOptions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/analyzeChain.js +47 -10
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/checkNullishAndReport.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/compareNodes.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/gatherLogicalOperands.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-promise-reject-errors.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-readonly-parameter-types.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-readonly.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-reduce-type-parameter.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-regexp-exec.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-return-this-type.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-string-starts-ends-with.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-ts-expect-error.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/promise-function-async.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/related-getter-setter-pairs.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/require-array-sort-compare.js +50 -3
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/require-await.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/restrict-plus-operands.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/restrict-template-expressions.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/return-await.js +12 -9
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/sort-type-constituents.js +3 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-boolean-expressions.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-void-return.d.ts +3 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-void-return.js +100 -5
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/switch-exhaustiveness-check.js +3 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/triple-slash-reference.js +6 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/typedef.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unbound-method.js +39 -12
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unified-signatures.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unified-signatures.js +75 -37
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/use-unknown-in-catch-callback-variable.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/FunctionSignature.d.ts +15 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/FunctionSignature.js +123 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/assertionFunctionUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/astUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/baseTypeUtils.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/baseTypeUtils.js +17 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/classScopeAnalyzer.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/extractComputedName.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/collectUnusedVariables.js +11 -7
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/createRule.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/escapeRegExp.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/explicitReturnTypeUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getAwaitTokenRemovalRange.d.ts +4 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getAwaitTokenRemovalRange.js +15 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getBaseTypesOfClassMember.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getConstraintInfo.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getESLintCoreRule.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getFixOrSuggest.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getForStatementHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getFunctionHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getMemberHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getOperatorPrecedence.js +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getParentFunctionNode.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getStaticStringValue.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getStringLength.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getTextWithParentheses.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getThisExpression.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getValueOfLiteralType.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getWrappedCode.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getWrappingFixer.js +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/hasOverloadSignatures.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/index.d.ts +4 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/index.js +5 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isArrayMethodCallWithPredicate.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isAssignee.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isConditionalTest.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isHigherPrecedenceThanAwait.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isNodeEqual.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isNullLiteral.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isPromiseAggregatorMethod.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfArrowFunctionBodyNeedingParentheses.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfArrowFunctionBodyNeedingParentheses.js +30 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfExpressionStatement.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfExpressionStatementNeedingParentheses.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfExpressionStatementNeedingParentheses.js +9 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isTypeImport.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isTypeOnlyReference.d.ts +4 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isTypeOnlyReference.js +23 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isUndefinedIdentifier.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/lazyRules.d.ts +6 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/lazyRules.js +18 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/misc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/needsPrecedingSemiColon.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/needsToBeAwaited.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/objectIterators.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/promiseUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/rangeToLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/referenceContainsTypePredicate.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/referenceContainsTypeQuery.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/scopeUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/skipChainExpression.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/truthinessUtils.js +3 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/walkStatements.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/package.json +19 -18
- package/node_modules/@typescript-eslint/parser/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/parser/dist/parser.js +1 -0
- package/node_modules/@typescript-eslint/parser/package.json +9 -8
- package/node_modules/@typescript-eslint/project-service/dist/createProjectService.js +10 -9
- package/node_modules/@typescript-eslint/project-service/dist/getParsedConfigFileFromTSServer.js +1 -0
- package/node_modules/@typescript-eslint/project-service/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/project-service/dist/throttleOpenedFileCleanup.d.ts +7 -0
- package/node_modules/@typescript-eslint/project-service/dist/throttleOpenedFileCleanup.js +37 -0
- package/node_modules/@typescript-eslint/project-service/package.json +7 -6
- package/node_modules/@typescript-eslint/scope-manager/dist/ID.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/ScopeManager.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/analyze.js +3 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/assert.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/CatchClauseDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ClassNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/Definition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/DefinitionBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/DefinitionType.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/FunctionNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ImplicitGlobalVariableDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ImportBindingDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ParameterDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSEnumMemberDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSEnumNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSModuleNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TypeDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/VariableDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/base-config.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/decorators.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/decorators.legacy.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.core.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.generator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.proxy.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.reflect.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.symbol.wellknown.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.array.include.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.arraybuffer.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.typedarrays.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.asyncgenerator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.bigint.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.number.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.symbol.wellknown.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.weakref.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.error.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.arraybuffer.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.float16.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.iterator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es5.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es6.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es7.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.bigint.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.decorators.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.disposable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.error.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.float16.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.iterator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.temporal.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.typedarrays.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.weakref.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/lib.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/scripthost.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.importscripts.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ClassVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ExportVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ImportVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/PatternVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Reference.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Referencer.js +13 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/TypeVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Visitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/VisitorBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/BlockScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/CatchScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassFieldInitializerScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassStaticBlockScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ConditionalTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ForScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionExpressionNameScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/GlobalScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/MappedTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ModuleScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/Scope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ScopeBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ScopeType.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/SwitchScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TSEnumScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TSModuleScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/WithScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/ESLintScopeVariable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/ImplicitLibVariable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/Variable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/VariableBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/package.json +8 -7
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/compilerOptions.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/getParsedConfigFile.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/package.json +4 -3
- package/node_modules/@typescript-eslint/type-utils/dist/TypeOrValueSpecifier.js +4 -14
- package/node_modules/@typescript-eslint/type-utils/dist/builtinSymbolLikes.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/containsAllTypesByName.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/discriminateAnyType.js +7 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getConstrainedTypeAtLocation.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getContextualType.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getDeclaration.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getSourceFileOfNode.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getTypeName.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isSymbolFromDefaultLibrary.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isTypeBrandedLiteralLike.js +3 -1
- package/node_modules/@typescript-eslint/type-utils/dist/isTypeReadonly.js +10 -5
- package/node_modules/@typescript-eslint/type-utils/dist/isUnsafeAssignment.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/predicates.d.ts +5 -0
- package/node_modules/@typescript-eslint/type-utils/dist/predicates.js +11 -0
- package/node_modules/@typescript-eslint/type-utils/dist/propertyTypes.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/requiresQuoting.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeFlagUtils.js +2 -1
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/specifierNameMatches.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/specifierSourceMatches.d.ts +3 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/specifierSourceMatches.js +19 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInFile.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInLib.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInPackageDeclarationFile.d.ts +1 -1
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInPackageDeclarationFile.js +87 -9
- package/node_modules/@typescript-eslint/type-utils/package.json +9 -8
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts +3 -3
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/lib.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/parser-options.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/ts-estree.js +1 -0
- package/node_modules/@typescript-eslint/types/package.json +8 -7
- package/node_modules/@typescript-eslint/typescript-estree/dist/ast-converter.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/check-modifiers.js +7 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/check-syntax-errors.js +8 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js +3 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.d.ts +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.js +12 -2
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/WatchCompilerHostOfConfigFile.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createIsolatedProgram.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgramError.js +3 -2
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createSourceFile.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getScriptKind.js +2 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js +14 -6
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.d.ts +23 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js +86 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/useProvidedPrograms.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/validateDefaultProjectForFilesGlob.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/createParserServices.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/getImportClausePhaseModifier.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/jsx/xhtml-entities.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/node-utils.js +48 -2
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/candidateTSConfigRootDirs.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js +2 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/inferSingleRun.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/warnAboutTSVersion.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser-options.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/semantic-or-syntactic-errors.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/source-files.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/estree-to-ts-node-types.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/ts-nodes.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/use-at-your-own-risk.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/useProgramFromProjectService.js +45 -4
- package/node_modules/@typescript-eslint/typescript-estree/dist/version-check.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/version.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/withoutProjectParserOptions.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/package.json +9 -8
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/PatternMatcher.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/ReferenceTracker.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/astUtilities.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/predicates.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/scopeAnalysis.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/helpers.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/misc.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/predicates.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/InferTypesFromRule.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/RuleCreator.js +2 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/applyDefault.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/deepMerge.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/getParserServices.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/nullThrows.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/parserSeemsToBeTSESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/json-schema.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/AST.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Config.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/ESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Linter.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Parser.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/ParserOptions.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Processor.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Rule.d.ts +17 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Rule.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/RuleTester.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Scope.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/SourceCode.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/ESLintShared.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/FlatESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/LegacyESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-estree.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/NoInfer.d.ts +1 -1
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/NoInfer.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/isArray.js +1 -0
- package/node_modules/@typescript-eslint/utils/package.json +7 -6
- package/node_modules/@typescript-eslint/visitor-keys/dist/get-keys.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/dist/visitor-keys.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/package.json +6 -5
- package/node_modules/dependency-cruiser/node_modules/ignore/LICENSE-MIT +21 -0
- package/node_modules/dependency-cruiser/node_modules/ignore/README.md +452 -0
- package/node_modules/dependency-cruiser/node_modules/ignore/index.d.ts +81 -0
- package/node_modules/dependency-cruiser/node_modules/ignore/index.js +793 -0
- package/node_modules/dependency-cruiser/node_modules/ignore/legacy.js +690 -0
- package/node_modules/dependency-cruiser/node_modules/ignore/package.json +87 -0
- package/node_modules/get-tsconfig/dist/index.cjs +4 -4
- package/node_modules/get-tsconfig/dist/index.mjs +4 -4
- package/node_modules/get-tsconfig/package.json +1 -1
- package/node_modules/ignore/README.md +49 -0
- package/node_modules/ignore/index.js +906 -162
- package/node_modules/ignore/legacy.js +760 -127
- package/node_modules/ignore/package.json +10 -4
- package/node_modules/typescript-eslint/dist/compatibility-types.js +1 -0
- package/node_modules/typescript-eslint/dist/config-helper.js +1 -0
- package/node_modules/typescript-eslint/dist/getTSConfigRootDirFromStack.js +1 -0
- package/node_modules/typescript-eslint/dist/globs.js +1 -0
- package/node_modules/typescript-eslint/dist/index.js +2 -0
- package/node_modules/typescript-eslint/package.json +13 -20
- package/package.json +11 -9
- package/plugins/swarm/README.md +31 -14
- package/plugins/swarm/{skills/scan/SKILL.md → references/scan.md} +6 -13
- package/schema/zedbee.schema.json +12 -0
|
@@ -2,7 +2,7 @@ import { inspectManagedCheck } from "../applicability.js";
|
|
|
2
2
|
import { changedFilePaths } from "../changed-file-paths.js";
|
|
3
3
|
import { relative, sep } from "node:path";
|
|
4
4
|
import { Linter } from "eslint";
|
|
5
|
-
import { collectMetricEntitySpans } from "../../attribution/entities.js";
|
|
5
|
+
import { collectMetricEntitySpans, } from "../../attribution/entities.js";
|
|
6
6
|
import { compareCodeUnits } from "../../core/compare.js";
|
|
7
7
|
import { canonicalizeSnapshotRoot } from "../../inspection/read-json.js";
|
|
8
8
|
import { CheckIncompleteError } from "../incomplete-error.js";
|
|
@@ -10,6 +10,7 @@ import { createManagedEslint } from "../eslint/load-engine.js";
|
|
|
10
10
|
import { managedConfig } from "../eslint/managed-config.js";
|
|
11
11
|
import { analysisKey, analysisStore } from "../analysis-reuse.js";
|
|
12
12
|
import { parseComplexityMetric, } from "./metric-message.js";
|
|
13
|
+
import { pairClassMetricObservations, } from "./pair-class-metrics.js";
|
|
13
14
|
const SOURCE = /\.(?:js|jsx|mjs|cjs|ts|tsx|mts|cts)$/iu;
|
|
14
15
|
function workspaceFor(inspection, target) {
|
|
15
16
|
return inspection.workspaces.find(({ relativeRoot }) => relativeRoot === target.relativeRoot);
|
|
@@ -48,8 +49,66 @@ function observationsFromMessages(file, source, messages, limit) {
|
|
|
48
49
|
}),
|
|
49
50
|
})));
|
|
50
51
|
}
|
|
52
|
+
/** Index syntax intervals once; queries visit only possible containing spans. */
|
|
53
|
+
function metricSpanLookup(spans, source) {
|
|
54
|
+
const ordered = spans
|
|
55
|
+
.map((span, ordinal) => ({
|
|
56
|
+
span,
|
|
57
|
+
ordinal,
|
|
58
|
+
start: span.startOffset,
|
|
59
|
+
end: span.endOffset,
|
|
60
|
+
}))
|
|
61
|
+
.sort((left, right) => left.start - right.start || left.ordinal - right.ordinal);
|
|
62
|
+
const maxEnds = [];
|
|
63
|
+
function build(node, start, end) {
|
|
64
|
+
if (end - start === 1)
|
|
65
|
+
return (maxEnds[node] = ordered[start].end);
|
|
66
|
+
const middle = (start + end) >>> 1;
|
|
67
|
+
return (maxEnds[node] = Math.max(build(node * 2, start, middle), build(node * 2 + 1, middle, end)));
|
|
68
|
+
}
|
|
69
|
+
if (ordered.length > 0)
|
|
70
|
+
build(1, 0, ordered.length);
|
|
71
|
+
return (offset) => {
|
|
72
|
+
let best;
|
|
73
|
+
function containing(node, start, end) {
|
|
74
|
+
if (ordered[start].start > offset || maxEnds[node] <= offset)
|
|
75
|
+
return;
|
|
76
|
+
if (end - start === 1) {
|
|
77
|
+
const candidate = ordered[start];
|
|
78
|
+
if (best === undefined ||
|
|
79
|
+
candidate.end - candidate.start < best.end - best.start ||
|
|
80
|
+
(candidate.end - candidate.start === best.end - best.start &&
|
|
81
|
+
candidate.ordinal < best.ordinal))
|
|
82
|
+
best = candidate;
|
|
83
|
+
return;
|
|
84
|
+
}
|
|
85
|
+
const middle = (start + end) >>> 1;
|
|
86
|
+
containing(node * 2, start, middle);
|
|
87
|
+
containing(node * 2 + 1, middle, end);
|
|
88
|
+
}
|
|
89
|
+
if (ordered.length > 0)
|
|
90
|
+
containing(1, 0, ordered.length);
|
|
91
|
+
if (best !== undefined)
|
|
92
|
+
return best.span;
|
|
93
|
+
// Declaration diagnostics can precede their function on the same line.
|
|
94
|
+
let start = 0;
|
|
95
|
+
let end = ordered.length;
|
|
96
|
+
while (start < end) {
|
|
97
|
+
const middle = (start + end) >>> 1;
|
|
98
|
+
if (ordered[middle].start < offset)
|
|
99
|
+
start = middle + 1;
|
|
100
|
+
else
|
|
101
|
+
end = middle;
|
|
102
|
+
}
|
|
103
|
+
const next = ordered[start];
|
|
104
|
+
return next !== undefined &&
|
|
105
|
+
!source.slice(offset, next.start).includes("\n")
|
|
106
|
+
? next.span
|
|
107
|
+
: undefined;
|
|
108
|
+
};
|
|
109
|
+
}
|
|
51
110
|
function rawObservationsFromMessages(file, source, messages, limit) {
|
|
52
|
-
const
|
|
111
|
+
const spanAt = metricSpanLookup(collectMetricEntitySpans(source, file), source);
|
|
53
112
|
if (messages.some((message) => message.fatal === true)) {
|
|
54
113
|
throw new Error("Complexity analysis failed.");
|
|
55
114
|
}
|
|
@@ -62,16 +121,7 @@ function rawObservationsFromMessages(file, source, messages, limit) {
|
|
|
62
121
|
throw new Error("Complexity analysis failed.");
|
|
63
122
|
}
|
|
64
123
|
const offset = (starts[message.line - 1] ?? source.length) + message.column - 1;
|
|
65
|
-
const
|
|
66
|
-
.filter(({ startOffset, endOffset }) => offset >= startOffset && offset < endOffset)
|
|
67
|
-
.sort((left, right) => left.endOffset -
|
|
68
|
-
left.startOffset -
|
|
69
|
-
(right.endOffset - right.startOffset))[0];
|
|
70
|
-
const span = containing ??
|
|
71
|
-
spans
|
|
72
|
-
.filter(({ startOffset }) => startOffset >= offset &&
|
|
73
|
-
!source.slice(offset, startOffset).includes("\n"))
|
|
74
|
-
.sort((left, right) => left.startOffset - right.startOffset)[0];
|
|
124
|
+
const span = spanAt(offset);
|
|
75
125
|
if (span === undefined)
|
|
76
126
|
throw new Error("Complexity metric had no canonical syntax entity.");
|
|
77
127
|
const check = metric.name === "cyclomatic-complexity"
|
|
@@ -156,7 +206,7 @@ async function collectSide(snapshotRoot, inspection, target, checkId, metricName
|
|
|
156
206
|
policyForFile(checkId, path, side).when === "always")
|
|
157
207
|
.sort(compareCodeUnits);
|
|
158
208
|
if (files.length === 0)
|
|
159
|
-
return
|
|
209
|
+
return { observations: [], files: {} };
|
|
160
210
|
const engine = createManagedEslint({
|
|
161
211
|
cwd: canonicalRoot,
|
|
162
212
|
mode: "complexity",
|
|
@@ -165,6 +215,7 @@ async function collectSide(snapshotRoot, inspection, target, checkId, metricName
|
|
|
165
215
|
const results = await engine.lintFiles(files);
|
|
166
216
|
const allowed = new Set(files);
|
|
167
217
|
const observations = [];
|
|
218
|
+
const sources = {};
|
|
168
219
|
for (const result of results) {
|
|
169
220
|
const file = relative(canonicalRoot, result.filePath).split(sep).join("/");
|
|
170
221
|
if (!allowed.has(file))
|
|
@@ -173,6 +224,7 @@ async function collectSide(snapshotRoot, inspection, target, checkId, metricName
|
|
|
173
224
|
continue;
|
|
174
225
|
if (result.source === undefined)
|
|
175
226
|
throw new Error("Complexity analysis failed.");
|
|
227
|
+
sources[file] = result.source;
|
|
176
228
|
try {
|
|
177
229
|
const policy = policyForFile(checkId, file, side);
|
|
178
230
|
observations.push(...observationsFromMessages(file, result.source, result.messages, policy.max).filter(({ metric }) => metric?.name === metricName));
|
|
@@ -186,7 +238,10 @@ async function collectSide(snapshotRoot, inspection, target, checkId, metricName
|
|
|
186
238
|
});
|
|
187
239
|
}
|
|
188
240
|
}
|
|
189
|
-
return
|
|
241
|
+
return {
|
|
242
|
+
observations: Object.freeze(observations.sort((left, right) => compareCodeUnits(left.identity, right.identity))),
|
|
243
|
+
files: sources,
|
|
244
|
+
};
|
|
190
245
|
}
|
|
191
246
|
function createComplexityAdapter(id, metricName) {
|
|
192
247
|
return {
|
|
@@ -195,13 +250,12 @@ function createComplexityAdapter(id, metricName) {
|
|
|
195
250
|
inspect: (context) => inspectManagedCheck(id, context),
|
|
196
251
|
async collect(context) {
|
|
197
252
|
try {
|
|
198
|
-
const
|
|
199
|
-
const
|
|
253
|
+
const baseline = await collectSide(context.snapshots.baselineDir, context.baselineInspection, context.target, id, metricName, context.policyForFile, "baseline", changedFilePaths(context, "baseline"));
|
|
254
|
+
const target = await collectSide(context.snapshots.targetDir, context.targetInspection, context.target, id, metricName, context.policyForFile, "target", changedFilePaths(context, "target"));
|
|
200
255
|
return {
|
|
201
256
|
checkId: id,
|
|
202
257
|
target: context.target,
|
|
203
|
-
|
|
204
|
-
targetObservations,
|
|
258
|
+
...pairClassMetricObservations(baseline, target, context.changeSet),
|
|
205
259
|
};
|
|
206
260
|
}
|
|
207
261
|
catch (error) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.js","sourceRoot":"","sources":["../../../src/checks/complexity/adapter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,C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C7B,CAAC,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { Observation } from "../../core/types.js";
|
|
2
|
+
import type { ChangeSet } from "../../git/change-set.js";
|
|
3
|
+
export interface ComplexitySnapshot {
|
|
4
|
+
readonly observations: readonly Observation[];
|
|
5
|
+
readonly files: Readonly<Record<string, string>>;
|
|
6
|
+
}
|
|
7
|
+
/** Pair class-scoped baseline metrics to canonical target entities before delta attribution. */
|
|
8
|
+
export declare function pairClassMetricObservations(baseline: ComplexitySnapshot, target: ComplexitySnapshot, changeSet: ChangeSet): {
|
|
9
|
+
readonly baselineObservations: readonly Observation[];
|
|
10
|
+
readonly targetObservations: readonly Observation[];
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=pair-class-metrics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pair-class-metrics.d.ts","sourceRoot":"","sources":["../../../src/checks/complexity/pair-class-metrics.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAEzD,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,YAAY,EAAE,SAAS,WAAW,EAAE,CAAC;IAC9C,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;CAClD;AAuPD,gGAAgG;AAChG,wBAAgB,2BAA2B,CACzC,QAAQ,EAAE,kBAAkB,EAC5B,MAAM,EAAE,kBAAkB,EAC1B,SAAS,EAAE,SAAS,GACnB;IACD,QAAQ,CAAC,oBAAoB,EAAE,SAAS,WAAW,EAAE,CAAC;IACtD,QAAQ,CAAC,kBAAkB,EAAE,SAAS,WAAW,EAAE,CAAC;CACrD,CAsBA"}
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { diffLines } from "diff";
|
|
2
|
+
import { collectMetricEntitySpans, } from "../../attribution/entities.js";
|
|
3
|
+
function members(source, file) {
|
|
4
|
+
return collectMetricEntitySpans(source, file).flatMap((span) => {
|
|
5
|
+
const payload = span.entity.identity.slice(`${span.entity.kind}:${file}:`.length);
|
|
6
|
+
const segments = payload.split("/");
|
|
7
|
+
const scopes = segments.flatMap((segment, index) => segment.startsWith("class-scope=")
|
|
8
|
+
? [segments.slice(0, index + 1).join("/")]
|
|
9
|
+
: []);
|
|
10
|
+
if (scopes.length === 0)
|
|
11
|
+
return [];
|
|
12
|
+
return [
|
|
13
|
+
{
|
|
14
|
+
span,
|
|
15
|
+
payload,
|
|
16
|
+
scopes,
|
|
17
|
+
sourceKey: JSON.stringify([
|
|
18
|
+
span.entity.kind,
|
|
19
|
+
span.entity.name,
|
|
20
|
+
payload
|
|
21
|
+
.replace(/class-scope=[^/]+/gu, "class-scope=*")
|
|
22
|
+
.replace(/field-scope=[^/]+/gu, "field-scope=*"),
|
|
23
|
+
source.slice(span.startOffset, span.endOffset),
|
|
24
|
+
]),
|
|
25
|
+
},
|
|
26
|
+
];
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
function scopeOwner(scope) {
|
|
30
|
+
const segments = scope.split("/");
|
|
31
|
+
return segments.slice(0, -1).join("/");
|
|
32
|
+
}
|
|
33
|
+
function groupedScopes(input) {
|
|
34
|
+
const result = new Map();
|
|
35
|
+
for (const member of input) {
|
|
36
|
+
for (const scope of member.scopes) {
|
|
37
|
+
const owner = scopeOwner(scope);
|
|
38
|
+
const group = result.get(owner) ?? new Set();
|
|
39
|
+
group.add(scope);
|
|
40
|
+
result.set(owner, group);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return result;
|
|
44
|
+
}
|
|
45
|
+
function remapScope(owner, pairs) {
|
|
46
|
+
for (let end = owner.length; end > 0; end = owner.lastIndexOf("/", end - 1)) {
|
|
47
|
+
const prefix = owner.slice(0, end);
|
|
48
|
+
const matched = pairs.get(prefix);
|
|
49
|
+
if (matched !== undefined)
|
|
50
|
+
return matched + owner.slice(end);
|
|
51
|
+
}
|
|
52
|
+
return owner;
|
|
53
|
+
}
|
|
54
|
+
function pairFileMembers(file, before, after, changeSet) {
|
|
55
|
+
const baseline = members(before, file);
|
|
56
|
+
const target = members(after, file);
|
|
57
|
+
if (baseline.length === 0 || target.length === 0)
|
|
58
|
+
return new Map();
|
|
59
|
+
const components = diffLines(before, after, { timeout: 2_000 });
|
|
60
|
+
if (components === undefined)
|
|
61
|
+
throw new Error("Complexity comparison timed out.");
|
|
62
|
+
const unchanged = [];
|
|
63
|
+
let baselineLine = 1;
|
|
64
|
+
let targetLine = 1;
|
|
65
|
+
for (const component of components) {
|
|
66
|
+
const count = component.count ?? 0;
|
|
67
|
+
if (!component.added && !component.removed)
|
|
68
|
+
unchanged.push({ before: baselineLine, after: targetLine, count });
|
|
69
|
+
if (!component.added)
|
|
70
|
+
baselineLine += count;
|
|
71
|
+
if (!component.removed)
|
|
72
|
+
targetLine += count;
|
|
73
|
+
}
|
|
74
|
+
const ranges = changeSet.files.get(file)?.addedRanges ?? [];
|
|
75
|
+
const edited = (member) => ranges.some(({ start, end }) => member.span.entity.startLine <= end &&
|
|
76
|
+
member.span.entity.endLine >= start);
|
|
77
|
+
const baselineCounts = new Map();
|
|
78
|
+
for (const member of baseline)
|
|
79
|
+
baselineCounts.set(member.sourceKey, (baselineCounts.get(member.sourceKey) ?? 0) + 1);
|
|
80
|
+
const targetGroups = new Map();
|
|
81
|
+
for (const member of target) {
|
|
82
|
+
const group = targetGroups.get(member.sourceKey) ?? {
|
|
83
|
+
members: [],
|
|
84
|
+
unedited: [],
|
|
85
|
+
uneditedByLines: new Map(),
|
|
86
|
+
};
|
|
87
|
+
group.members.push(member);
|
|
88
|
+
if (!edited(member)) {
|
|
89
|
+
group.unedited.push(member);
|
|
90
|
+
const lines = `${member.span.entity.startLine}:${member.span.entity.endLine}`;
|
|
91
|
+
const atLines = group.uneditedByLines.get(lines) ?? [];
|
|
92
|
+
atLines.push(member);
|
|
93
|
+
group.uneditedByLines.set(lines, atLines);
|
|
94
|
+
}
|
|
95
|
+
targetGroups.set(member.sourceKey, group);
|
|
96
|
+
}
|
|
97
|
+
const anchors = new Map();
|
|
98
|
+
for (const member of baseline) {
|
|
99
|
+
const group = targetGroups.get(member.sourceKey);
|
|
100
|
+
if (group === undefined)
|
|
101
|
+
continue;
|
|
102
|
+
const candidates = group.members;
|
|
103
|
+
let start = 0;
|
|
104
|
+
let end = unchanged.length;
|
|
105
|
+
while (start < end) {
|
|
106
|
+
const middle = (start + end) >>> 1;
|
|
107
|
+
if (unchanged[middle].before <= member.span.entity.startLine)
|
|
108
|
+
start = middle + 1;
|
|
109
|
+
else
|
|
110
|
+
end = middle;
|
|
111
|
+
}
|
|
112
|
+
const range = unchanged[start - 1];
|
|
113
|
+
const span = range !== undefined &&
|
|
114
|
+
member.span.entity.endLine < range.before + range.count
|
|
115
|
+
? range
|
|
116
|
+
: undefined;
|
|
117
|
+
const delta = span === undefined ? undefined : span.after - span.before;
|
|
118
|
+
const mapped = delta === undefined
|
|
119
|
+
? []
|
|
120
|
+
: (group.uneditedByLines.get(`${member.span.entity.startLine + delta}:${member.span.entity.endLine + delta}`) ?? []);
|
|
121
|
+
const unedited = group.unedited;
|
|
122
|
+
const uniqueBefore = baselineCounts.get(member.sourceKey) === 1;
|
|
123
|
+
const candidate = mapped.length === 1
|
|
124
|
+
? mapped[0]
|
|
125
|
+
: uniqueBefore && unedited.length === 1
|
|
126
|
+
? unedited[0]
|
|
127
|
+
: uniqueBefore && candidates.length === 1
|
|
128
|
+
? candidates[0]
|
|
129
|
+
: undefined;
|
|
130
|
+
if (candidate !== undefined)
|
|
131
|
+
anchors.set(member, candidate);
|
|
132
|
+
}
|
|
133
|
+
// Source anchors must be one-to-one before they can establish class ownership.
|
|
134
|
+
const anchorCounts = new Map();
|
|
135
|
+
for (const candidate of anchors.values())
|
|
136
|
+
anchorCounts.set(candidate, (anchorCounts.get(candidate) ?? 0) + 1);
|
|
137
|
+
for (const [member, candidate] of anchors) {
|
|
138
|
+
if (anchorCounts.get(candidate) > 1)
|
|
139
|
+
anchors.delete(member);
|
|
140
|
+
}
|
|
141
|
+
const forward = new Map();
|
|
142
|
+
const backward = new Map();
|
|
143
|
+
for (const [member, candidate] of anchors) {
|
|
144
|
+
for (const [index, scope] of member.scopes.entries()) {
|
|
145
|
+
const matched = candidate.scopes[index];
|
|
146
|
+
const choices = forward.get(scope) ?? new Set();
|
|
147
|
+
choices.add(matched);
|
|
148
|
+
forward.set(scope, choices);
|
|
149
|
+
const origins = backward.get(matched) ?? new Set();
|
|
150
|
+
origins.add(scope);
|
|
151
|
+
backward.set(matched, origins);
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
const scopePairs = new Map();
|
|
155
|
+
for (const [scope, choices] of forward) {
|
|
156
|
+
const [candidate] = choices;
|
|
157
|
+
if (choices.size === 1 && backward.get(candidate)?.size === 1)
|
|
158
|
+
scopePairs.set(scope, candidate);
|
|
159
|
+
}
|
|
160
|
+
const pairedTargets = new Set(scopePairs.values());
|
|
161
|
+
const oldScopes = groupedScopes(baseline);
|
|
162
|
+
const newScopes = groupedScopes(target);
|
|
163
|
+
// After source anchors, only a single remaining old/new class can be paired
|
|
164
|
+
// without guessing among rewritten siblings. Equal counts do not prove order.
|
|
165
|
+
for (const [owner, siblings] of [...oldScopes].sort(([left], [right]) => left.length - right.length)) {
|
|
166
|
+
const newOwner = remapScope(owner, scopePairs);
|
|
167
|
+
const candidates = newScopes.get(newOwner);
|
|
168
|
+
if (candidates?.size !== siblings.size)
|
|
169
|
+
continue;
|
|
170
|
+
if ([...siblings].some((scope) => (forward.has(scope) && !scopePairs.has(scope)) ||
|
|
171
|
+
(scopePairs.has(scope) && !candidates.has(scopePairs.get(scope)))))
|
|
172
|
+
continue;
|
|
173
|
+
const unmatchedOld = [...siblings].filter((scope) => !scopePairs.has(scope));
|
|
174
|
+
const unmatchedNew = [...candidates].filter((scope) => !pairedTargets.has(scope));
|
|
175
|
+
if (unmatchedOld.length === 1 && unmatchedNew.length === 1) {
|
|
176
|
+
scopePairs.set(unmatchedOld[0], unmatchedNew[0]);
|
|
177
|
+
pairedTargets.add(unmatchedNew[0]);
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
const identities = new Map();
|
|
181
|
+
const targetByPayload = new Map(target.map((member) => [member.payload, member]));
|
|
182
|
+
for (const member of baseline) {
|
|
183
|
+
const anchor = anchors.get(member);
|
|
184
|
+
const candidate = anchor ?? targetByPayload.get(remapScope(member.payload, scopePairs));
|
|
185
|
+
const hasPairedScope = member.scopes.every((scope) => scopePairs.has(scope));
|
|
186
|
+
if (candidate !== undefined &&
|
|
187
|
+
(anchor !== undefined || hasPairedScope) &&
|
|
188
|
+
member.span.entity.kind === candidate.span.entity.kind &&
|
|
189
|
+
member.span.entity.name === candidate.span.entity.name)
|
|
190
|
+
identities.set(member.span.entity.identity, candidate.span.entity.identity);
|
|
191
|
+
}
|
|
192
|
+
return identities;
|
|
193
|
+
}
|
|
194
|
+
/** Pair class-scoped baseline metrics to canonical target entities before delta attribution. */
|
|
195
|
+
export function pairClassMetricObservations(baseline, target, changeSet) {
|
|
196
|
+
const mappings = new Map();
|
|
197
|
+
return {
|
|
198
|
+
baselineObservations: baseline.observations.flatMap((observation) => {
|
|
199
|
+
if (!observation.identity.includes("class-scope="))
|
|
200
|
+
return [observation];
|
|
201
|
+
const file = observation.entity?.file;
|
|
202
|
+
if (file === undefined)
|
|
203
|
+
return [];
|
|
204
|
+
let identities = mappings.get(file);
|
|
205
|
+
if (identities === undefined) {
|
|
206
|
+
const before = baseline.files[file];
|
|
207
|
+
const after = target.files[file];
|
|
208
|
+
identities =
|
|
209
|
+
before === undefined || after === undefined
|
|
210
|
+
? new Map()
|
|
211
|
+
: pairFileMembers(file, before, after, changeSet);
|
|
212
|
+
mappings.set(file, identities);
|
|
213
|
+
}
|
|
214
|
+
const identity = identities.get(observation.identity);
|
|
215
|
+
return identity === undefined ? [] : [{ ...observation, identity }];
|
|
216
|
+
}),
|
|
217
|
+
targetObservations: target.observations,
|
|
218
|
+
};
|
|
219
|
+
}
|
|
220
|
+
//# sourceMappingURL=pair-class-metrics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pair-class-metrics.js","sourceRoot":"","sources":["../../../src/checks/complexity/pair-class-metrics.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,MAAM,CAAC;AACjC,OAAO,EACL,wBAAwB,GAEzB,MAAM,+BAA+B,CAAC;AAgBvC,SAAS,OAAO,CAAC,MAAc,EAAE,IAAY;IAC3C,OAAO,wBAAwB,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE;QAC7D,MAAM,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CACxC,GAAG,IAAI,CAAC,MAAM,CAAC,IAAI,IAAI,IAAI,GAAG,CAAC,MAAM,CACtC,CAAC;QACF,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACpC,MAAM,MAAM,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,KAAK,EAAE,EAAE,CACjD,OAAO,CAAC,UAAU,CAAC,cAAc,CAAC;YAChC,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YAC1C,CAAC,CAAC,EAAE,CACP,CAAC;QACF,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;YAAE,OAAO,EAAE,CAAC;QACnC,OAAO;YACL;gBACE,IAAI;gBACJ,OAAO;gBACP,MAAM;gBACN,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC;oBACxB,IAAI,CAAC,MAAM,CAAC,IAAI;oBAChB,IAAI,CAAC,MAAM,CA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AAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,GAAG,WAAW,EAAE,QAAQ,EAAE,CAAC,CAAC;QACtE,CAAC,CAAC;QACF,kBAAkB,EAAE,MAAM,CAAC,YAAY;KACxC,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../src/checks/dead-code/adapter.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../../../src/checks/dead-code/adapter.ts"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAIV,uBAAuB,EACxB,MAAM,eAAe,CAAC;AA6GvB,eAAO,MAAM,eAAe,EAAE,uBAyF7B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { loadSnapshotAliases, sourceModuleSpecifiers, } from "../typescript/aliases.js";
|
|
1
2
|
import { inspectManagedCheck } from "../applicability.js";
|
|
2
|
-
import
|
|
3
|
+
import { projectInputsMayHaveChanged } from "../project-inputs.js";
|
|
3
4
|
import { compareCodeUnits } from "../../core/compare.js";
|
|
4
5
|
import { canonicalizeSnapshotRoot, readContainedFile, } from "../../inspection/read-json.js";
|
|
5
6
|
import { captureSnapshotRegistry } from "../../inspection/snapshot-registry.js";
|
|
@@ -9,103 +10,24 @@ import { exportCurrentAnalysisSourceCapture } from "../../inspection/source-capt
|
|
|
9
10
|
import { runCapturedKnip } from "./executor.js";
|
|
10
11
|
import { createManagedKnipConfig } from "./managed-config.js";
|
|
11
12
|
import { parseKnipReport } from "./parse-report.js";
|
|
12
|
-
import { createKnipImportValidator
|
|
13
|
+
import { createKnipImportValidator } from "./import-boundary.js";
|
|
13
14
|
const SOURCE = /\.(?:js|jsx|mjs|cjs|ts|tsx|mts|cts)$/iu;
|
|
14
15
|
const INERT_TSCONFIG = ".zedbee-managed-no-tsconfig.json";
|
|
15
16
|
function workspaceFor(inspection, target) {
|
|
16
17
|
return inspection.workspaces.find(({ relativeRoot }) => relativeRoot === target.relativeRoot);
|
|
17
18
|
}
|
|
18
|
-
function staticModuleSpecifier(node, hasNodeModuleImport) {
|
|
19
|
-
if ((ts.isImportDeclaration(node) || ts.isExportDeclaration(node)) &&
|
|
20
|
-
node.moduleSpecifier !== undefined &&
|
|
21
|
-
ts.isStringLiteralLike(node.moduleSpecifier)) {
|
|
22
|
-
return node.moduleSpecifier.text;
|
|
23
|
-
}
|
|
24
|
-
if (ts.isImportEqualsDeclaration(node) &&
|
|
25
|
-
ts.isExternalModuleReference(node.moduleReference) &&
|
|
26
|
-
node.moduleReference.expression !== undefined &&
|
|
27
|
-
ts.isStringLiteralLike(node.moduleReference.expression)) {
|
|
28
|
-
return node.moduleReference.expression.text;
|
|
29
|
-
}
|
|
30
|
-
if (ts.isImportTypeNode(node) &&
|
|
31
|
-
ts.isLiteralTypeNode(node.argument) &&
|
|
32
|
-
ts.isStringLiteralLike(node.argument.literal)) {
|
|
33
|
-
return node.argument.literal.text;
|
|
34
|
-
}
|
|
35
|
-
if (ts.isCallExpression(node) &&
|
|
36
|
-
node.arguments.length >= 1 &&
|
|
37
|
-
ts.isStringLiteralLike(node.arguments[0]) &&
|
|
38
|
-
(node.expression.kind === ts.SyntaxKind.ImportKeyword ||
|
|
39
|
-
(ts.isIdentifier(node.expression) &&
|
|
40
|
-
node.expression.text === "require" &&
|
|
41
|
-
node.arguments.length === 1) ||
|
|
42
|
-
(ts.isPropertyAccessExpression(node.expression) &&
|
|
43
|
-
((ts.isIdentifier(node.expression.expression) &&
|
|
44
|
-
node.expression.expression.text === "require") ||
|
|
45
|
-
(ts.isMetaProperty(node.expression.expression) &&
|
|
46
|
-
node.expression.expression.keywordToken ===
|
|
47
|
-
ts.SyntaxKind.ImportKeyword)) &&
|
|
48
|
-
node.expression.name.text === "resolve"))) {
|
|
49
|
-
return node.arguments[0].text;
|
|
50
|
-
}
|
|
51
|
-
if (hasNodeModuleImport &&
|
|
52
|
-
ts.isCallExpression(node) &&
|
|
53
|
-
node.arguments[0] &&
|
|
54
|
-
ts.isStringLiteralLike(node.arguments[0]) &&
|
|
55
|
-
((ts.isIdentifier(node.expression) &&
|
|
56
|
-
node.expression.text === "register") ||
|
|
57
|
-
(ts.isPropertyAccessExpression(node.expression) &&
|
|
58
|
-
ts.isIdentifier(node.expression.expression) &&
|
|
59
|
-
node.expression.expression.text === "module" &&
|
|
60
|
-
node.expression.name.text === "register"))) {
|
|
61
|
-
const base = node.arguments[1];
|
|
62
|
-
if (!node.arguments[0].text.startsWith(".") ||
|
|
63
|
-
(base &&
|
|
64
|
-
ts.isPropertyAccessExpression(base) &&
|
|
65
|
-
ts.isMetaProperty(base.expression) &&
|
|
66
|
-
base.name.text === "url"))
|
|
67
|
-
return node.arguments[0].text;
|
|
68
|
-
}
|
|
69
|
-
return undefined;
|
|
70
|
-
}
|
|
71
19
|
async function validateSnapshotInputs(snapshotRoot, workspace, capture) {
|
|
72
20
|
const registry = await captureSnapshotRegistry(snapshotRoot);
|
|
21
|
+
const aliases = await loadSnapshotAliases(snapshotRoot, workspace);
|
|
73
22
|
const { validateImport, collectCommentImports } = await createKnipImportValidator(registry, capture === undefined
|
|
74
23
|
? undefined
|
|
75
|
-
: async (path) => capture.assertMissing(path));
|
|
24
|
+
: async (path) => capture.assertMissing(path), (sourcePath, specifier) => aliases.resolve(sourcePath, specifier));
|
|
76
25
|
if (registry.resolve(INERT_TSCONFIG) !== undefined) {
|
|
77
26
|
throw new TypeError("Reserved managed Knip path is present");
|
|
78
27
|
}
|
|
79
28
|
for (const sourcePath of workspace.sourceFiles) {
|
|
80
29
|
const source = await readContainedFile(registry, sourcePath);
|
|
81
|
-
const
|
|
82
|
-
const hasNodeModuleImport = file.statements.some((statement) => ts.isImportDeclaration(statement) &&
|
|
83
|
-
ts.isStringLiteralLike(statement.moduleSpecifier) &&
|
|
84
|
-
["node:module", "module"].includes(statement.moduleSpecifier.text));
|
|
85
|
-
const specifiers = [];
|
|
86
|
-
const comments = new Map();
|
|
87
|
-
const visit = (node) => {
|
|
88
|
-
for (const comment of [
|
|
89
|
-
...(ts.getLeadingCommentRanges(source, node.pos) ?? []),
|
|
90
|
-
...(ts.getTrailingCommentRanges(source, node.end) ?? []),
|
|
91
|
-
]) {
|
|
92
|
-
const block = comment.kind === ts.SyntaxKind.MultiLineCommentTrivia;
|
|
93
|
-
comments.set(comment.pos, {
|
|
94
|
-
type: block ? "Block" : "Line",
|
|
95
|
-
start: comment.pos,
|
|
96
|
-
end: comment.end,
|
|
97
|
-
value: source.slice(comment.pos + 2, comment.end - (block ? 2 : 0)),
|
|
98
|
-
});
|
|
99
|
-
}
|
|
100
|
-
const specifier = staticModuleSpecifier(node, hasNodeModuleImport);
|
|
101
|
-
if (specifier !== undefined) {
|
|
102
|
-
specifiers.push(specifier);
|
|
103
|
-
}
|
|
104
|
-
ts.forEachChild(node, visit);
|
|
105
|
-
};
|
|
106
|
-
visit(file);
|
|
107
|
-
collectCommentImports([...comments.values()], file.statements[0]?.getStart(file) ?? source.length, (specifier) => specifiers.push(specifier));
|
|
108
|
-
for (const specifier of specifiers) {
|
|
30
|
+
for (const specifier of sourceModuleSpecifiers(sourcePath, source, collectCommentImports)) {
|
|
109
31
|
await validateImport(sourcePath, specifier);
|
|
110
32
|
}
|
|
111
33
|
}
|
|
@@ -128,7 +50,7 @@ async function collectSide(snapshotRoot, inspection, target, signal, captureCont
|
|
|
128
50
|
context: captureContext,
|
|
129
51
|
snapshotRoot: canonicalRoot,
|
|
130
52
|
workspace: workspace.relativeRoot,
|
|
131
|
-
config: await createManagedKnipConfig(canonicalRoot, inspection),
|
|
53
|
+
config: await createManagedKnipConfig(canonicalRoot, inspection, workspace, async (path) => guards.assertMissing(path)),
|
|
132
54
|
...(sourceCapture === undefined ? {} : { sourceCapture }),
|
|
133
55
|
}, signal);
|
|
134
56
|
signal.throwIfAborted();
|
|
@@ -140,17 +62,6 @@ async function collectSide(snapshotRoot, inspection, target, signal, captureCont
|
|
|
140
62
|
: { dependencyInputs: result.dependencyInputs }),
|
|
141
63
|
};
|
|
142
64
|
}
|
|
143
|
-
function hasProjectDelta(context) {
|
|
144
|
-
const workspaces = [
|
|
145
|
-
...context.baselineInspection.workspaces,
|
|
146
|
-
...context.targetInspection.workspaces,
|
|
147
|
-
].filter(({ relativeRoot }) => relativeRoot === context.target.relativeRoot);
|
|
148
|
-
const owned = new Set(workspaces.flatMap((workspace) => [
|
|
149
|
-
workspace.manifestPath,
|
|
150
|
-
...workspace.sourceFiles,
|
|
151
|
-
]));
|
|
152
|
-
return [...context.changeSet.files.keys()].some((path) => owned.has(path));
|
|
153
|
-
}
|
|
154
65
|
export const deadCodeAdapter = {
|
|
155
66
|
id: "deadCode",
|
|
156
67
|
output: "observations",
|
|
@@ -207,7 +118,7 @@ export const deadCodeAdapter = {
|
|
|
207
118
|
baselineObservations: baseline.observations,
|
|
208
119
|
targetObservations: target.observations,
|
|
209
120
|
...(dependencyInputs === undefined ? {} : { dependencyInputs }),
|
|
210
|
-
projectDelta:
|
|
121
|
+
projectDelta: await projectInputsMayHaveChanged(context, context.target),
|
|
211
122
|
};
|
|
212
123
|
}
|
|
213
124
|
catch (error) {
|