@opensip-cli/fitness 0.1.10 → 0.1.12
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 +4 -2
- package/dist/__tests__/check-utils.test.js +11 -0
- package/dist/__tests__/check-utils.test.js.map +1 -1
- package/dist/__tests__/fit-execute-opts.test.js +35 -1
- package/dist/__tests__/fit-execute-opts.test.js.map +1 -1
- package/dist/__tests__/public-api.test.js +7 -2
- package/dist/__tests__/public-api.test.js.map +1 -1
- package/dist/__tests__/tool.test.js +18 -9
- package/dist/__tests__/tool.test.js.map +1 -1
- package/dist/check-utils/check-authoring-helpers.d.ts +14 -0
- package/dist/check-utils/check-authoring-helpers.d.ts.map +1 -0
- package/dist/check-utils/check-authoring-helpers.js +18 -0
- package/dist/check-utils/check-authoring-helpers.js.map +1 -0
- package/dist/check-utils/index.d.ts +1 -0
- package/dist/check-utils/index.d.ts.map +1 -1
- package/dist/check-utils/index.js +1 -0
- package/dist/check-utils/index.js.map +1 -1
- package/dist/check-utils/test-helpers.d.ts.map +1 -1
- package/dist/check-utils/test-helpers.js +0 -1
- package/dist/check-utils/test-helpers.js.map +1 -1
- package/dist/cli/__tests__/fit-fail-closed.test.d.ts +8 -0
- package/dist/cli/__tests__/fit-fail-closed.test.d.ts.map +1 -0
- package/dist/cli/__tests__/fit-fail-closed.test.js +200 -0
- package/dist/cli/__tests__/fit-fail-closed.test.js.map +1 -0
- package/dist/cli/__tests__/fit-modes-live.test.js +33 -3
- package/dist/cli/__tests__/fit-modes-live.test.js.map +1 -1
- package/dist/cli/__tests__/fit-runner.test.d.ts +5 -0
- package/dist/cli/__tests__/fit-runner.test.d.ts.map +1 -0
- package/dist/cli/__tests__/fit-runner.test.js +145 -0
- package/dist/cli/__tests__/fit-runner.test.js.map +1 -0
- package/dist/cli/__tests__/report-data.test.js +37 -2
- package/dist/cli/__tests__/report-data.test.js.map +1 -1
- package/dist/cli/fit/__tests__/envelope-view-table.test.d.ts +2 -0
- package/dist/cli/fit/__tests__/envelope-view-table.test.d.ts.map +1 -0
- package/dist/cli/fit/__tests__/envelope-view-table.test.js +64 -0
- package/dist/cli/fit/__tests__/envelope-view-table.test.js.map +1 -0
- package/dist/cli/fit/__tests__/fit-export-command-spec.test.js +5 -2
- package/dist/cli/fit/__tests__/fit-export-command-spec.test.js.map +1 -1
- package/dist/cli/fit/check-loader.d.ts.map +1 -1
- package/dist/cli/fit/check-loader.js +28 -25
- package/dist/cli/fit/check-loader.js.map +1 -1
- package/dist/cli/fit/envelope-view.d.ts +1 -3
- package/dist/cli/fit/envelope-view.d.ts.map +1 -1
- package/dist/cli/fit/envelope-view.js +1 -7
- package/dist/cli/fit/envelope-view.js.map +1 -1
- package/dist/cli/fit/fit-aux-command-specs.d.ts +4 -4
- package/dist/cli/fit/fit-aux-command-specs.d.ts.map +1 -1
- package/dist/cli/fit/fit-aux-command-specs.js +13 -15
- package/dist/cli/fit/fit-aux-command-specs.js.map +1 -1
- package/dist/cli/fit/fit-command-spec.d.ts +3 -3
- package/dist/cli/fit/fit-command-spec.d.ts.map +1 -1
- package/dist/cli/fit/fit-command-spec.js +5 -9
- package/dist/cli/fit/fit-command-spec.js.map +1 -1
- package/dist/cli/fit/load-outcome.d.ts +24 -0
- package/dist/cli/fit/load-outcome.d.ts.map +1 -0
- package/dist/cli/fit/load-outcome.js +203 -0
- package/dist/cli/fit/load-outcome.js.map +1 -0
- package/dist/cli/fit/resolved-fitness-config.d.ts.map +1 -1
- package/dist/cli/fit/resolved-fitness-config.js +2 -6
- package/dist/cli/fit/resolved-fitness-config.js.map +1 -1
- package/dist/cli/fit/result-builders.d.ts.map +1 -1
- package/dist/cli/fit/result-builders.js +3 -4
- package/dist/cli/fit/result-builders.js.map +1 -1
- package/dist/cli/fit-modes.d.ts.map +1 -1
- package/dist/cli/fit-modes.js +51 -19
- package/dist/cli/fit-modes.js.map +1 -1
- package/dist/cli/fit-runner-progress.d.ts +0 -2
- package/dist/cli/fit-runner-progress.d.ts.map +1 -1
- package/dist/cli/fit-runner-progress.js +0 -3
- package/dist/cli/fit-runner-progress.js.map +1 -1
- package/dist/cli/fit-runner.d.ts +1 -34
- package/dist/cli/fit-runner.d.ts.map +1 -1
- package/dist/cli/fit-runner.js +90 -241
- package/dist/cli/fit-runner.js.map +1 -1
- package/dist/cli/fit-worker.d.ts.map +1 -1
- package/dist/cli/fit-worker.js +0 -1
- package/dist/cli/fit-worker.js.map +1 -1
- package/dist/cli/fit.d.ts +1 -0
- package/dist/cli/fit.d.ts.map +1 -1
- package/dist/cli/fit.js +6 -0
- package/dist/cli/fit.js.map +1 -1
- package/dist/cli/report-data.d.ts.map +1 -1
- package/dist/cli/report-data.js +0 -1
- package/dist/cli/report-data.js.map +1 -1
- package/dist/framework/__tests__/define-check.test.js +0 -1
- package/dist/framework/__tests__/define-check.test.js.map +1 -1
- package/dist/framework/__tests__/define-regex-list-check.test.js +15 -0
- package/dist/framework/__tests__/define-regex-list-check.test.js.map +1 -1
- package/dist/framework/__tests__/scope-registry.test.js +2 -0
- package/dist/framework/__tests__/scope-registry.test.js.map +1 -1
- package/dist/framework/abortable-exec.d.ts.map +1 -1
- package/dist/framework/abortable-exec.js +0 -1
- package/dist/framework/abortable-exec.js.map +1 -1
- package/dist/framework/check-config.d.ts +0 -8
- package/dist/framework/check-config.d.ts.map +1 -1
- package/dist/framework/check-config.js +0 -1
- package/dist/framework/check-config.js.map +1 -1
- package/dist/framework/constants.d.ts.map +1 -1
- package/dist/framework/constants.js +0 -1
- package/dist/framework/constants.js.map +1 -1
- package/dist/framework/define-check.d.ts.map +1 -1
- package/dist/framework/define-check.js +0 -3
- package/dist/framework/define-check.js.map +1 -1
- package/dist/framework/define-regex-list-check.d.ts +6 -0
- package/dist/framework/define-regex-list-check.d.ts.map +1 -1
- package/dist/framework/define-regex-list-check.js +4 -0
- package/dist/framework/define-regex-list-check.js.map +1 -1
- package/dist/framework/execution-context.d.ts.map +1 -1
- package/dist/framework/execution-context.js +0 -2
- package/dist/framework/execution-context.js.map +1 -1
- package/dist/framework/file-accessor.d.ts.map +1 -1
- package/dist/framework/file-accessor.js +0 -4
- package/dist/framework/file-accessor.js.map +1 -1
- package/dist/framework/file-cache.d.ts +1 -0
- package/dist/framework/file-cache.d.ts.map +1 -1
- package/dist/framework/file-cache.js +1 -4
- package/dist/framework/file-cache.js.map +1 -1
- package/dist/framework/ignore-processing.d.ts.map +1 -1
- package/dist/framework/ignore-processing.js +0 -2
- package/dist/framework/ignore-processing.js.map +1 -1
- package/dist/framework/import-graph.d.ts.map +1 -1
- package/dist/framework/import-graph.js +0 -1
- package/dist/framework/import-graph.js.map +1 -1
- package/dist/framework/parse-cache.d.ts.map +1 -1
- package/dist/framework/parse-cache.js +0 -1
- package/dist/framework/parse-cache.js.map +1 -1
- package/dist/framework/scope-registry.d.ts.map +1 -1
- package/dist/framework/scope-registry.js +7 -1
- package/dist/framework/scope-registry.js.map +1 -1
- package/dist/framework/severity-mapping.d.ts.map +1 -1
- package/dist/framework/severity-mapping.js +0 -1
- package/dist/framework/severity-mapping.js.map +1 -1
- package/dist/identity.d.ts +11 -0
- package/dist/identity.d.ts.map +1 -0
- package/dist/identity.js +11 -0
- package/dist/identity.js.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/persistence/session-replay.d.ts.map +1 -1
- package/dist/persistence/session-replay.js +7 -28
- package/dist/persistence/session-replay.js.map +1 -1
- package/dist/plugins/loader.d.ts.map +1 -1
- package/dist/plugins/loader.js +2 -1
- package/dist/plugins/loader.js.map +1 -1
- package/dist/recipes/__tests__/execution-branches.test.d.ts.map +1 -1
- package/dist/recipes/__tests__/execution-branches.test.js +0 -1
- package/dist/recipes/__tests__/execution-branches.test.js.map +1 -1
- package/dist/recipes/__tests__/service.test.d.ts.map +1 -1
- package/dist/recipes/__tests__/service.test.js +0 -1
- package/dist/recipes/__tests__/service.test.js.map +1 -1
- package/dist/recipes/built-in-recipes.d.ts.map +1 -1
- package/dist/recipes/built-in-recipes.js +0 -1
- package/dist/recipes/built-in-recipes.js.map +1 -1
- package/dist/recipes/check-resolution.d.ts.map +1 -1
- package/dist/recipes/check-resolution.js +0 -1
- package/dist/recipes/check-resolution.js.map +1 -1
- package/dist/recipes/check-result-processor.d.ts.map +1 -1
- package/dist/recipes/check-result-processor.js +0 -1
- package/dist/recipes/check-result-processor.js.map +1 -1
- package/dist/recipes/registry.d.ts.map +1 -1
- package/dist/recipes/registry.js +0 -1
- package/dist/recipes/registry.js.map +1 -1
- package/dist/recipes/service-adhoc.d.ts +24 -0
- package/dist/recipes/service-adhoc.d.ts.map +1 -0
- package/dist/recipes/service-adhoc.js +53 -0
- package/dist/recipes/service-adhoc.js.map +1 -0
- package/dist/recipes/service-check-resolution.d.ts +18 -0
- package/dist/recipes/service-check-resolution.d.ts.map +1 -0
- package/dist/recipes/service-check-resolution.js +65 -0
- package/dist/recipes/service-check-resolution.js.map +1 -0
- package/dist/recipes/service-prepare.d.ts +23 -0
- package/dist/recipes/service-prepare.d.ts.map +1 -0
- package/dist/recipes/service-prepare.js +30 -0
- package/dist/recipes/service-prepare.js.map +1 -0
- package/dist/recipes/service-prewarm.d.ts +12 -0
- package/dist/recipes/service-prewarm.d.ts.map +1 -0
- package/dist/recipes/service-prewarm.js +25 -0
- package/dist/recipes/service-prewarm.js.map +1 -0
- package/dist/recipes/service-session.d.ts +17 -0
- package/dist/recipes/service-session.d.ts.map +1 -0
- package/dist/recipes/service-session.js +78 -0
- package/dist/recipes/service-session.js.map +1 -0
- package/dist/recipes/service.d.ts +2 -19
- package/dist/recipes/service.d.ts.map +1 -1
- package/dist/recipes/service.js +23 -219
- package/dist/recipes/service.js.map +1 -1
- package/dist/scaffold/index.d.ts +3 -0
- package/dist/scaffold/index.d.ts.map +1 -0
- package/dist/scaffold/index.js +3 -0
- package/dist/scaffold/index.js.map +1 -0
- package/dist/scope-augmentation.d.ts +11 -0
- package/dist/scope-augmentation.d.ts.map +1 -1
- package/dist/signalers/loader.d.ts.map +1 -1
- package/dist/signalers/loader.js +0 -3
- package/dist/signalers/loader.js.map +1 -1
- package/dist/targets/loader.d.ts.map +1 -1
- package/dist/targets/loader.js +0 -3
- package/dist/targets/loader.js.map +1 -1
- package/dist/targets/target-registry.d.ts.map +1 -1
- package/dist/targets/target-registry.js +0 -1
- package/dist/targets/target-registry.js.map +1 -1
- package/dist/tool.d.ts.map +1 -1
- package/dist/tool.js +12 -16
- package/dist/tool.js.map +1 -1
- package/dist/types/severity.d.ts.map +1 -1
- package/dist/types/severity.js +0 -2
- package/dist/types/severity.js.map +1 -1
- package/package.json +27 -16
- package/dist/cli/fit-runner-views.d.ts +0 -33
- package/dist/cli/fit-runner-views.d.ts.map +0 -1
- package/dist/cli/fit-runner-views.js +0 -92
- package/dist/cli/fit-runner-views.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"target-registry.d.ts","sourceRoot":"","sources":["../../src/targets/target-registry.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"target-registry.d.ts","sourceRoot":"","sources":["../../src/targets/target-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EAAE,cAAc,IAAI,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AAEnF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAczC;;;;;GAKG;AACH,qBAAa,cAAe,SAAQ,uBAAuB;IACzD;;;;;;;;;;;;;;;OAeG;IACH,WAAW,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,GAAG,SAAS,MAAM,EAAE;CAwB1F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"target-registry.js","sourceRoot":"","sources":["../../src/targets/target-registry.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"target-registry.js","sour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E,EAAE,CAAC,cAAc,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;YAE/D,OAAO,aAAa,IAAI,YAAY,CAAC;QACvC,CAAC,CAAC,CAAC;IACL,CAAC;CACF"}
|
package/dist/tool.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool.d.ts","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;
|
|
1
|
+
{"version":3,"file":"tool.d.ts","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AAiCH,OAAO,yBAAyB,CAAC;AAKjC,OAAO,KAAK,EAGV,IAAI,EAEL,MAAM,mBAAmB,CAAC;AAwI3B;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB,UAAU,CAAC;AAMhD,eAAO,MAAM,iBAAiB,yCAAyC,CAAC;AAExE,eAAO,MAAM,WAAW,EAAE,IA8BxB,CAAC"}
|
package/dist/tool.js
CHANGED
|
@@ -50,17 +50,17 @@
|
|
|
50
50
|
import { defineTool, readPackageVersion } from '@opensip-cli/core';
|
|
51
51
|
import { fitnessFingerprintStrategy } from './baseline-strategy.js';
|
|
52
52
|
import { fitExportCommandSpec, fitListGroupedCommandSpec, fitRecipesGroupedCommandSpec, } from './cli/fit/fit-aux-command-specs.js';
|
|
53
|
-
import { buildFitCommandSpec
|
|
53
|
+
import { buildFitCommandSpec } from './cli/fit/fit-command-spec.js';
|
|
54
54
|
import { renderFitLive } from './cli/fit-runner.js';
|
|
55
55
|
import { fitRunWorkerCommandSpec } from './cli/fit-worker.js';
|
|
56
56
|
import { collectFitnessReportData } from './cli/report-data.js';
|
|
57
57
|
import { fitnessConfigDeclaration } from './config/fitness-config-schema.js';
|
|
58
58
|
import { FileCache } from './framework/file-cache.js';
|
|
59
59
|
import { createCheckRegistry, createFitnessLoadState, createRecipeRegistry, currentCheckRegistry, currentRecipeRegistry, } from './framework/scope-registry.js';
|
|
60
|
+
import { FITNESS_IDENTITY, FITNESS_LIVE_VIEW_KEY } from './identity.js';
|
|
60
61
|
import { fitReplayFromSession } from './persistence/session-replay.js';
|
|
61
62
|
import { FIT_PLUGIN_LAYOUT } from './plugins/loader.js';
|
|
62
|
-
import { fitScaffoldConfigBlock } from './scaffold/
|
|
63
|
-
import { fitScaffoldExamples, fitStableExampleIds } from './scaffold/examples.js';
|
|
63
|
+
import { fitScaffoldConfigBlock, fitScaffoldExamples, fitStableExampleIds, } from './scaffold/index.js';
|
|
64
64
|
// Side-effect import: ensures the RunScope.fitness augmentation is loaded so
|
|
65
65
|
// `scope.fitness` is the correctly-typed slot here.
|
|
66
66
|
import './scope-augmentation.js';
|
|
@@ -82,7 +82,7 @@ import './scope-augmentation.js';
|
|
|
82
82
|
* to the old mount-time registration.
|
|
83
83
|
*/
|
|
84
84
|
function setUpFitLiveView(cli) {
|
|
85
|
-
cli.registerLiveView(
|
|
85
|
+
cli.registerLiveView(FITNESS_LIVE_VIEW_KEY, async (args, liveContext) => {
|
|
86
86
|
const fitArgs = args;
|
|
87
87
|
// The host always supplies the LiveViewContext (carrying the run timer for
|
|
88
88
|
// the summary provider). The renderer returns a ToolRunCompletion; the HOST
|
|
@@ -205,30 +205,26 @@ export const FITNESS_CONTRACT_VERSION = '1.0.0';
|
|
|
205
205
|
// =============================================================================
|
|
206
206
|
export const FITNESS_STABLE_ID = 'afd68bd3-ff3c-4935-a5b6-76d8fc7a5224';
|
|
207
207
|
export const fitnessTool = defineTool({
|
|
208
|
+
identity: FITNESS_IDENTITY,
|
|
208
209
|
metadata: {
|
|
209
|
-
id: FITNESS_STABLE_ID,
|
|
210
|
-
// tool-command-surface-taxonomy Task 2.4 (Q1): metadata.name == the command
|
|
211
|
-
// verb (`fit`). The config namespace key stays `fitness:` — it keys off the
|
|
212
|
-
// DECOUPLED `fitnessConfigDeclaration.namespace = 'fitness'` literal, NOT
|
|
213
|
-
// metadata.name, so existing `fitness:` config blocks keep validating. The
|
|
214
|
-
// session `tool` column is already `'fit'` (sessionReplay.tool + the session
|
|
215
|
-
// contributions), so aligning the name REDUCES mismatch. Q6 (decided): keep
|
|
216
|
-
// the `fitness:` config namespace — no `fit:` alias or migration.
|
|
217
|
-
name: 'fit', // command verb + human key (was 'fitness')
|
|
210
|
+
id: FITNESS_STABLE_ID,
|
|
218
211
|
version: readPackageVersion(import.meta.url),
|
|
219
212
|
description: 'Run fitness checks against a codebase',
|
|
220
213
|
},
|
|
221
|
-
pluginLayout: FIT_PLUGIN_LAYOUT,
|
|
214
|
+
pluginLayout: { userSubdirs: FIT_PLUGIN_LAYOUT.userSubdirs },
|
|
222
215
|
commandSpecs: fitCommandSpecs,
|
|
223
216
|
extensionPoints: {
|
|
224
217
|
fitnessContractVersion: FITNESS_CONTRACT_VERSION,
|
|
225
218
|
contributeScope,
|
|
226
219
|
collectReportData: collectFitnessReportData,
|
|
227
220
|
sessionReplay: {
|
|
228
|
-
tool: 'fit',
|
|
229
221
|
replaySession: fitReplayFromSession,
|
|
230
222
|
},
|
|
231
|
-
config:
|
|
223
|
+
config: {
|
|
224
|
+
schema: fitnessConfigDeclaration.schema,
|
|
225
|
+
defaults: fitnessConfigDeclaration.defaults,
|
|
226
|
+
env: fitnessConfigDeclaration.env,
|
|
227
|
+
},
|
|
232
228
|
capabilityRegistrars: { 'fit-pack': registerFitCheck, 'fit-recipe': registerFitRecipe },
|
|
233
229
|
fingerprintStrategy: fitnessFingerprintStrategy,
|
|
234
230
|
scaffoldExamples: fitScaffoldExamples,
|
package/dist/tool.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool.js","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AA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AW,GAAS,UAAU,CAAC;IAC1C,QAAQ,EAAE,gBAAgB;IAC1B,QAAQ,EAAE;QACR,EAAE,EAAE,iBAAiB;QACrB,OAAO,EAAE,kBAAkB,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC;QAC5C,WAAW,EAAE,uCAAuC;KACrD;IACD,YAAY,EAAE,EAAE,WAAW,EAAE,iBAAiB,CAAC,WAAW,EAAE;IAC5D,YAAY,EAAE,eAAe;IAC7B,eAAe,EAAE;QACf,sBAAsB,EAAE,wBAAwB;QAChD,eAAe;QACf,iBAAiB,EAAE,wBAAwB;QAC3C,aAAa,EAAE;YACb,aAAa,EAAE,oBAAoB;SACpC;QACD,MAAM,EAAE;YACN,MAAM,EAAE,wBAAwB,CAAC,MAAM;YACvC,QAAQ,EAAE,wBAAwB,CAAC,QAAQ;YAC3C,GAAG,EAAE,wBAAwB,CAAC,GAAG;SAClC;QACD,oBAAoB,EAAE,EAAE,UAAU,EAAE,gBAAgB,EAAE,YAAY,EAAE,iBAAiB,EAAE;QACvF,mBAAmB,EAAE,0BAA0B;QAC/C,gBAAgB,EAAE,mBAAmB;QACrC,gBAAgB,EAAE,mBAAmB;QACrC,mBAAmB,EAAE,sBAAsB;QAC3C,UAAU,EAAE,KAAK,IAAmB,EAAE;YACpC,0EAA0E;QAC5E,CAAC;KACF;CACF,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"severity.d.ts","sourceRoot":"","sources":["../../src/types/severity.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"severity.d.ts","sourceRoot":"","sources":["../../src/types/severity.ts"],"names":[],"mappings":"AACA;;;;;GAKG;AAWH,4CAA4C;AAC5C,wBAAgB,WAAW,CAAC,OAAO,EAAE,SAAS;IAAE,QAAQ,EAAE,MAAM,CAAA;CAAE,EAAE,GAAG,MAAM,CAM5E;AAED,8CAA8C;AAC9C,wBAAgB,aAAa,CAAC,OAAO,EAAE,SAAS;IAAE,QAAQ,EAAE,MAAM,CAAA;CAAE,EAAE,GAAG,MAAM,CAM9E"}
|
package/dist/types/severity.js
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
// @fitness-ignore-file batch-operation-limits -- iterates bounded collections (config entries, registry items, or small analysis results)
|
|
2
1
|
// @fitness-ignore-file clean-code-naming-quality -- short names used in severity mapping utilities
|
|
3
|
-
// @fitness-ignore-file project-readme-existence -- internal module, not a package root
|
|
4
2
|
/**
|
|
5
3
|
* @fileoverview Shared severity classification helpers
|
|
6
4
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"severity.js","sourceRoot":"","sources":["../../src/types/severity.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"severity.js","sourceRoot":"","sources":["../../src/types/severity.ts"],"names":[],"mappings":"AAAA,mGAAmG;AACnG;;;;;GAKG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAIpD,iEAAiE;AACjE,SAAS,iBAAiB,CAAC,QAAwB;IACjD,OAAO,QAAQ,KAAK,QAAQ,CAAC;AAC/B,CAAC;AAED,4CAA4C;AAC5C,MAAM,UAAU,WAAW,CAAC,OAAwC;IAClE,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,KAAK,MAAM,CAAC,IAAI,OAAO,EAAE,CAAC;QACxB,IAAI,eAAe,CAAC,CAAC,CAAC,QAA0B,CAAC;YAAE,KAAK,EAAE,CAAC;IAC7D,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,8CAA8C;AAC9C,MAAM,UAAU,aAAa,CAAC,OAAwC;IACpE,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,KAAK,MAAM,CAAC,IAAI,OAAO,EAAE,CAAC;QACxB,IAAI,iBAAiB,CAAC,CAAC,CAAC,QAA0B,CAAC;YAAE,KAAK,EAAE,CAAC;IAC/D,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opensip-cli/fitness",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.12",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"description": "Fitness checks engine for OpenSIP CLI",
|
|
6
6
|
"keywords": [
|
|
@@ -25,7 +25,8 @@
|
|
|
25
25
|
"main": "./dist/index.js",
|
|
26
26
|
"types": "./dist/index.d.ts",
|
|
27
27
|
"exports": {
|
|
28
|
-
".": "./dist/index.js"
|
|
28
|
+
".": "./dist/index.js",
|
|
29
|
+
"./internal": "./dist/internal.js"
|
|
29
30
|
},
|
|
30
31
|
"files": [
|
|
31
32
|
"dist",
|
|
@@ -34,13 +35,23 @@
|
|
|
34
35
|
],
|
|
35
36
|
"opensipTools": {
|
|
36
37
|
"kind": "tool",
|
|
37
|
-
"id": "
|
|
38
|
+
"id": "fitness",
|
|
39
|
+
"identity": {
|
|
40
|
+
"name": "fitness",
|
|
41
|
+
"aliases": [
|
|
42
|
+
"fit"
|
|
43
|
+
],
|
|
44
|
+
"layoutKey": "fit"
|
|
45
|
+
},
|
|
38
46
|
"stableId": "afd68bd3-ff3c-4935-a5b6-76d8fc7a5224",
|
|
39
47
|
"apiVersion": 1,
|
|
40
48
|
"commands": [
|
|
41
49
|
{
|
|
42
|
-
"name": "
|
|
50
|
+
"name": "fitness",
|
|
43
51
|
"description": "Run fitness checks",
|
|
52
|
+
"aliases": [
|
|
53
|
+
"fit"
|
|
54
|
+
],
|
|
44
55
|
"commonFlags": [
|
|
45
56
|
"cwd",
|
|
46
57
|
"json",
|
|
@@ -112,7 +123,7 @@
|
|
|
112
123
|
{
|
|
113
124
|
"name": "list",
|
|
114
125
|
"description": "List available fitness checks",
|
|
115
|
-
"parent": "
|
|
126
|
+
"parent": "fitness",
|
|
116
127
|
"commonFlags": [
|
|
117
128
|
"cwd",
|
|
118
129
|
"json"
|
|
@@ -123,7 +134,7 @@
|
|
|
123
134
|
{
|
|
124
135
|
"name": "recipes",
|
|
125
136
|
"description": "List available fitness recipes",
|
|
126
|
-
"parent": "
|
|
137
|
+
"parent": "fitness",
|
|
127
138
|
"commonFlags": [
|
|
128
139
|
"cwd",
|
|
129
140
|
"json"
|
|
@@ -134,7 +145,7 @@
|
|
|
134
145
|
{
|
|
135
146
|
"name": "export",
|
|
136
147
|
"description": "Export fit artifacts: --format baseline (the SARIF-shaped gate baseline)",
|
|
137
|
-
"parent": "
|
|
148
|
+
"parent": "fitness",
|
|
138
149
|
"commonFlags": [
|
|
139
150
|
"cwd",
|
|
140
151
|
"json"
|
|
@@ -233,24 +244,24 @@
|
|
|
233
244
|
"commander": "^15.0.0",
|
|
234
245
|
"drizzle-orm": "^0.45.2",
|
|
235
246
|
"glob": "^13.0.0",
|
|
236
|
-
"ink": "^7.0.5",
|
|
237
247
|
"minimatch": "^10.2.5",
|
|
238
248
|
"react": "^19.2.7",
|
|
239
249
|
"typescript": "~6.0.3",
|
|
240
250
|
"zod": "^4.4.3",
|
|
241
|
-
"@opensip-cli/cli-ui": "0.1.
|
|
242
|
-
"@opensip-cli/
|
|
243
|
-
"@opensip-cli/
|
|
244
|
-
"@opensip-cli/
|
|
245
|
-
"@opensip-cli/
|
|
246
|
-
"@opensip-cli/
|
|
247
|
-
"@opensip-cli/
|
|
251
|
+
"@opensip-cli/cli-ui": "0.1.12",
|
|
252
|
+
"@opensip-cli/cli-live": "0.1.12",
|
|
253
|
+
"@opensip-cli/contracts": "0.1.12",
|
|
254
|
+
"@opensip-cli/config": "0.1.12",
|
|
255
|
+
"@opensip-cli/datastore": "0.1.12",
|
|
256
|
+
"@opensip-cli/core": "0.1.12",
|
|
257
|
+
"@opensip-cli/session-store": "0.1.12",
|
|
258
|
+
"@opensip-cli/targeting": "0.1.12"
|
|
248
259
|
},
|
|
249
260
|
"devDependencies": {
|
|
250
261
|
"@types/node": "^24.13.2",
|
|
251
262
|
"@types/react": "^19.2.17",
|
|
252
263
|
"vitest": "^4.1.8",
|
|
253
|
-
"@opensip-cli/lang-typescript": "0.1.
|
|
264
|
+
"@opensip-cli/lang-typescript": "0.1.12"
|
|
254
265
|
},
|
|
255
266
|
"scripts": {
|
|
256
267
|
"build": "tsc",
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview Tool-specific Ink render pieces for the live fit view.
|
|
3
|
-
*
|
|
4
|
-
* Extracted from `fit-runner.tsx` so the state-machine entry there stays
|
|
5
|
-
* compact. Each component here consumes the run's {@link SignalEnvelope}-
|
|
6
|
-
* derived view-models (`FitTableRow` / `FitFindingsGroup`, built by
|
|
7
|
-
* `fit/envelope-view.ts`) and pulls colours from the shared cli-ui theme. The
|
|
8
|
-
* Banner, RunHeader, Spinner, and ErrorMessage primitives remain owned by
|
|
9
|
-
* `@opensip-cli/cli-ui` — only the fitness-specific renderers live here.
|
|
10
|
-
*
|
|
11
|
-
* ADR-0011 Phase 6: fitness no longer imports `@opensip-cli/output`; the
|
|
12
|
-
* live table/findings derive straight from the envelope (the static/non-TTY
|
|
13
|
-
* path uses the shared `formatSignalTableRows` at the composition root).
|
|
14
|
-
*/
|
|
15
|
-
import React from 'react';
|
|
16
|
-
import { type FitTableRow } from './fit/envelope-view.js';
|
|
17
|
-
export declare function ResultsTable({ rows, }: {
|
|
18
|
-
readonly rows: readonly FitTableRow[];
|
|
19
|
-
}): React.ReactElement | null;
|
|
20
|
-
/**
|
|
21
|
-
* WarningsBlock — renders non-fatal user-facing warnings collected during
|
|
22
|
-
* the run (plugin load failures, unknown languages in config, missing
|
|
23
|
-
* check packages, etc.).
|
|
24
|
-
*
|
|
25
|
-
* These come through the run's collected warnings rather than direct stderr
|
|
26
|
-
* writes — emitting them during an active Ink render desyncs the renderer's
|
|
27
|
-
* frame tracking. Rendering them here through Ink keeps the live view's
|
|
28
|
-
* frame contract intact.
|
|
29
|
-
*/
|
|
30
|
-
export declare function WarningsBlock({ warnings, }: {
|
|
31
|
-
readonly warnings: readonly string[];
|
|
32
|
-
}): React.ReactElement;
|
|
33
|
-
//# sourceMappingURL=fit-runner-views.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fit-runner-views.d.ts","sourceRoot":"","sources":["../../src/cli/fit-runner-views.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAIH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAoB,KAAK,WAAW,EAAE,MAAM,wBAAwB,CAAC;AA2B5E,wBAAgB,YAAY,CAAC,EAC3B,IAAI,GACL,EAAE;IACD,QAAQ,CAAC,IAAI,EAAE,SAAS,WAAW,EAAE,CAAC;CACvC,GAAG,KAAK,CAAC,YAAY,GAAG,IAAI,CA0D5B;AAOD;;;;;;;;;GASG;AACH,wBAAgB,aAAa,CAAC,EAC5B,QAAQ,GACT,EAAE;IACD,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;CACtC,GAAG,KAAK,CAAC,YAAY,CAYrB"}
|
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
/**
|
|
3
|
-
* @fileoverview Tool-specific Ink render pieces for the live fit view.
|
|
4
|
-
*
|
|
5
|
-
* Extracted from `fit-runner.tsx` so the state-machine entry there stays
|
|
6
|
-
* compact. Each component here consumes the run's {@link SignalEnvelope}-
|
|
7
|
-
* derived view-models (`FitTableRow` / `FitFindingsGroup`, built by
|
|
8
|
-
* `fit/envelope-view.ts`) and pulls colours from the shared cli-ui theme. The
|
|
9
|
-
* Banner, RunHeader, Spinner, and ErrorMessage primitives remain owned by
|
|
10
|
-
* `@opensip-cli/cli-ui` — only the fitness-specific renderers live here.
|
|
11
|
-
*
|
|
12
|
-
* ADR-0011 Phase 6: fitness no longer imports `@opensip-cli/output`; the
|
|
13
|
-
* live table/findings derive straight from the envelope (the static/non-TTY
|
|
14
|
-
* path uses the shared `formatSignalTableRows` at the composition root).
|
|
15
|
-
*/
|
|
16
|
-
import { useTheme, sortFitRowPriority, parseValidatedCount } from '@opensip-cli/cli-ui';
|
|
17
|
-
import { Box, Text } from 'ink';
|
|
18
|
-
import { fitValidatedCell } from './fit/envelope-view.js';
|
|
19
|
-
function statusColor(theme, status) {
|
|
20
|
-
if (status === 'FAIL')
|
|
21
|
-
return theme.statusFail;
|
|
22
|
-
if (status === 'ERROR')
|
|
23
|
-
return theme.statusTimeout;
|
|
24
|
-
return theme.statusPass;
|
|
25
|
-
}
|
|
26
|
-
function ignoredColor(theme, ignored, validated) {
|
|
27
|
-
const total = parseValidatedCount(validated);
|
|
28
|
-
if (total === 0 || ignored === 0)
|
|
29
|
-
return theme.muted;
|
|
30
|
-
const pct = (ignored / total) * 100;
|
|
31
|
-
if (pct > 10)
|
|
32
|
-
return theme.error;
|
|
33
|
-
if (pct > 5)
|
|
34
|
-
return theme.warning;
|
|
35
|
-
return theme.muted;
|
|
36
|
-
}
|
|
37
|
-
function durationColor(theme, ms) {
|
|
38
|
-
if (ms >= 60_000)
|
|
39
|
-
return theme.error;
|
|
40
|
-
if (ms >= 30_000)
|
|
41
|
-
return theme.warning;
|
|
42
|
-
return theme.success;
|
|
43
|
-
}
|
|
44
|
-
export function ResultsTable({ rows, }) {
|
|
45
|
-
const theme = useTheme();
|
|
46
|
-
if (rows.length === 0)
|
|
47
|
-
return null;
|
|
48
|
-
const sorted = [...rows].sort((a, b) => sortFitRowPriority(a) - sortFitRowPriority(b));
|
|
49
|
-
const maxCheckWidth = Math.max(40, ...sorted.map((r) => r.check.length));
|
|
50
|
-
const widths = { status: 7, errors: 6, warnings: 8, validated: 12, ignored: 7, duration: 10 };
|
|
51
|
-
const headerCells = [
|
|
52
|
-
'Check'.padEnd(maxCheckWidth),
|
|
53
|
-
'Status'.padEnd(widths.status),
|
|
54
|
-
'Errors'.padEnd(widths.errors),
|
|
55
|
-
'Warnings'.padEnd(widths.warnings),
|
|
56
|
-
'Validated'.padEnd(widths.validated),
|
|
57
|
-
'Ignores'.padEnd(widths.ignored),
|
|
58
|
-
'Duration'.padEnd(widths.duration),
|
|
59
|
-
];
|
|
60
|
-
const separatorCells = [
|
|
61
|
-
'-'.repeat(maxCheckWidth),
|
|
62
|
-
'-'.repeat(widths.status),
|
|
63
|
-
'-'.repeat(widths.errors),
|
|
64
|
-
'-'.repeat(widths.warnings),
|
|
65
|
-
'-'.repeat(widths.validated),
|
|
66
|
-
'-'.repeat(widths.ignored),
|
|
67
|
-
'-'.repeat(widths.duration),
|
|
68
|
-
];
|
|
69
|
-
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { children: headerCells.join(' | ') }), _jsx(Text, { children: separatorCells.join('-|-') }), sorted.map((row, i) => {
|
|
70
|
-
const validatedCell = fitValidatedCell(row);
|
|
71
|
-
return (_jsxs(Text, { children: [row.check.padEnd(maxCheckWidth), ' | ', _jsx(Text, { color: statusColor(theme, row.status), children: row.status.padEnd(widths.status) }), ' | ', _jsx(Text, { color: row.errors > 0 ? theme.error : theme.success, children: String(row.errors).padEnd(widths.errors) }), ' | ', _jsx(Text, { color: row.warnings > 0 ? theme.warning : theme.muted, children: String(row.warnings).padEnd(widths.warnings) }), ' | ', validatedCell.padEnd(widths.validated), ' | ', _jsx(Text, { color: ignoredColor(theme, row.ignored, validatedCell), children: String(row.ignored).padEnd(widths.ignored) }), ' | ', _jsx(Text, { color: durationColor(theme, row.durationMs), children: row.duration.padEnd(widths.duration) })] }, i));
|
|
72
|
-
})] }));
|
|
73
|
-
}
|
|
74
|
-
// SummaryLine previously lived here — now provided by
|
|
75
|
-
// `@opensip-cli/cli-ui`'s shared `RunSummary` component so fit, graph,
|
|
76
|
-
// and future tools render the same single-line summary at the bottom
|
|
77
|
-
// of every run. fit-runner.tsx imports `RunSummary` directly.
|
|
78
|
-
/**
|
|
79
|
-
* WarningsBlock — renders non-fatal user-facing warnings collected during
|
|
80
|
-
* the run (plugin load failures, unknown languages in config, missing
|
|
81
|
-
* check packages, etc.).
|
|
82
|
-
*
|
|
83
|
-
* These come through the run's collected warnings rather than direct stderr
|
|
84
|
-
* writes — emitting them during an active Ink render desyncs the renderer's
|
|
85
|
-
* frame tracking. Rendering them here through Ink keeps the live view's
|
|
86
|
-
* frame contract intact.
|
|
87
|
-
*/
|
|
88
|
-
export function WarningsBlock({ warnings, }) {
|
|
89
|
-
const theme = useTheme();
|
|
90
|
-
return (_jsx(Box, { flexDirection: "column", paddingLeft: 2, paddingTop: 1, children: warnings.map((msg, i) => (_jsxs(Text, { color: theme.warning, children: ['! ', msg] }, i))) }));
|
|
91
|
-
}
|
|
92
|
-
//# sourceMappingURL=fit-runner-views.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fit-runner-views.js","sourceRoot":"","sources":["../../src/cli/fit-runner-views.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACxF,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAGhC,OAAO,EAAE,gBAAgB,EAAoB,MAAM,wBAAwB,CAAC;AAE5E,SAAS,WAAW,CAAC,KAAkC,EAAE,MAA6B;IACpF,IAAI,MAAM,KAAK,MAAM;QAAE,OAAO,KAAK,CAAC,UAAU,CAAC;IAC/C,IAAI,MAAM,KAAK,OAAO;QAAE,OAAO,KAAK,CAAC,aAAa,CAAC;IACnD,OAAO,KAAK,CAAC,UAAU,CAAC;AAC1B,CAAC;AAED,SAAS,YAAY,CACnB,KAAkC,EAClC,OAAe,EACf,SAAiB;IAEjB,MAAM,KAAK,GAAG,mBAAmB,CAAC,SAAS,CAAC,CAAC;IAC7C,IAAI,KAAK,KAAK,CAAC,IAAI,OAAO,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC,KAAK,CAAC;IACrD,MAAM,GAAG,GAAG,CAAC,OAAO,GAAG,K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