@funnelsgrove/cli 0.1.386 → 0.1.389
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/dist/cli.d.ts +1 -0
- package/dist/cli.js +21 -0
- package/dist/projectValidator.js +2 -2
- package/dist/selfUpdate.d.ts +7 -1
- package/dist/selfUpdate.js +54 -9
- package/funnel-contract-compatibility.json +31 -31
- package/package.json +1 -1
- package/template_docs/.funnelsgrove-docs.json +3 -3
- package/template_docs/docs/funnelsgrove/migrations/step-contract-v3.md +1 -1
- package/template_docs/funnel-docs.config.json +1 -1
- package/template_scaffold/.funnelsgrove-contract-tools.json +1 -1
- package/template_scaffold/.funnelsgrove-docs.json +3 -3
- package/template_scaffold/.funnelsgrove-scaffold.json +7 -7
- package/template_scaffold/docs/funnelsgrove/migrations/step-contract-v3.md +1 -1
- package/template_scaffold/funnel-docs.config.json +1 -1
- package/template_scaffold/src/contract/validate-funnel.cli.ts +3 -1
- package/template_validation/.funnelsgrove-contract-tools.json +1 -1
- package/template_validation/src/contract/validate-funnel.cli.ts +3 -1
package/dist/cli.d.ts
CHANGED
|
@@ -101,6 +101,7 @@ export declare const repairDownloadedManagedFiles: (targetDir: string, options?:
|
|
|
101
101
|
docsSourceDir?: string;
|
|
102
102
|
validationSourceDir?: string;
|
|
103
103
|
}) => Promise<void>;
|
|
104
|
+
export declare const upgradePreviousManagedValidator: (targetDir: string) => Promise<void>;
|
|
104
105
|
export type BoundedNpmCommandOptions = {
|
|
105
106
|
timeoutMs?: number;
|
|
106
107
|
terminationGraceMs?: number;
|
package/dist/cli.js
CHANGED
|
@@ -40,6 +40,7 @@ import { renderDocsHuman, renderDocsJson, } from './docsOutput.js';
|
|
|
40
40
|
import { applyTemplateDocsUpdate, inspectTemplateDocs, loadBundledDocs, planTemplateDocsUpdate, recoverTemplateDocs, resolveTemplateDocsConflict, } from './docsTransaction.js';
|
|
41
41
|
import { renderValidationHuman, renderValidationJson, } from './diagnosticOutput.js';
|
|
42
42
|
import { validateFunnel } from './funnelValidation.js';
|
|
43
|
+
import { RUNNER_PATH } from './projectValidator.js';
|
|
43
44
|
import { StepContractMigrationError, applyStepContractV2Migration, checkStepContractV2Migration, recoverStepContractV2Migration, resolveStepContractMigrationMode, stepContractMigrationReportPath, } from './stepContractMigration.js';
|
|
44
45
|
import { assertHasCohortData, assertHasConversionData, assertHasFunnelPathData, assertHasTransitionData, buildCohortReportPayload, buildConversionReportPayload, buildFunnelPathReportPayload, buildTransitionReportPayload, formatAnalyticsJson, formatCohortTable, formatConversionsTable, formatFunnelPathTable, formatTransitionsTable, normalizeAnalyticsOutputFormat, parseAnalyticsDate, parseAnalyticsPeriod, } from './analyticsOutput.js';
|
|
45
46
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
@@ -295,6 +296,7 @@ const validatePackagedFunnel = async (targetDir) => validateFunnel({
|
|
|
295
296
|
legacyCatalog: await loadPackagedLegacyDocsCatalog(),
|
|
296
297
|
});
|
|
297
298
|
export async function executeValidateCommand(input) {
|
|
299
|
+
await upgradePreviousManagedValidator(path.resolve(input.targetDir));
|
|
298
300
|
const result = await (input.validate ?? validatePackagedFunnel)(path.resolve(input.targetDir));
|
|
299
301
|
const outputInput = { command: 'validate', result };
|
|
300
302
|
return {
|
|
@@ -311,6 +313,7 @@ export async function auditLegacyFunnel(targetDir, validate = validatePackagedFu
|
|
|
311
313
|
catch {
|
|
312
314
|
return null;
|
|
313
315
|
}
|
|
316
|
+
await upgradePreviousManagedValidator(path.resolve(targetDir));
|
|
314
317
|
const result = await validate(path.resolve(targetDir));
|
|
315
318
|
const versionDiagnostic = result.diagnostics.find((diagnostic) => diagnostic.code === 'FG-VERSION-001' || diagnostic.code === 'FG-VERSION-002');
|
|
316
319
|
if (!versionDiagnostic)
|
|
@@ -331,6 +334,7 @@ export class FunnelValidationError extends CliContractError {
|
|
|
331
334
|
}
|
|
332
335
|
}
|
|
333
336
|
export async function runValidatedFunnelMutation(input) {
|
|
337
|
+
await upgradePreviousManagedValidator(path.resolve(input.targetDir));
|
|
334
338
|
const result = await (input.validate ?? validatePackagedFunnel)(path.resolve(input.targetDir));
|
|
335
339
|
if (!result.valid || result.exitCode !== 0 || result.diagnostics.length > 0) {
|
|
336
340
|
throw new FunnelValidationError(result);
|
|
@@ -551,6 +555,23 @@ export const repairDownloadedManagedFiles = async (targetDir, options = {}) => {
|
|
|
551
555
|
await resolveTemplateDocsConflict(bundle, targetDir, conflict.path);
|
|
552
556
|
}
|
|
553
557
|
};
|
|
558
|
+
// FUN-547: the managed runner that funnels received before it learned to start as vite-node.mjs.
|
|
559
|
+
const PREVIOUS_MANAGED_RUNNER_SHA256 = '1b268b194865d633c760b704a0d4552adc2eb4526801da138ab2a4036f643d58';
|
|
560
|
+
export const upgradePreviousManagedValidator = async (targetDir) => {
|
|
561
|
+
try {
|
|
562
|
+
const runner = await readTargetRegularFile(targetDir, RUNNER_PATH);
|
|
563
|
+
if (runner === null || createHash('sha256').update(runner).digest('hex') !== PREVIOUS_MANAGED_RUNNER_SHA256) {
|
|
564
|
+
return;
|
|
565
|
+
}
|
|
566
|
+
await copyManagedValidationFiles(targetDir);
|
|
567
|
+
process.stderr.write('Updated the managed validator in src/contract/ to the current version.\n');
|
|
568
|
+
}
|
|
569
|
+
catch (error) {
|
|
570
|
+
// Local changes or symlinks: validation then reports the outdated validator.
|
|
571
|
+
if (!(error instanceof CliContractError && error.code === 'FG-DOC-002'))
|
|
572
|
+
throw error;
|
|
573
|
+
}
|
|
574
|
+
};
|
|
554
575
|
const loadManagedSyncPaths = async () => {
|
|
555
576
|
const docsBundle = await loadBundledDocs(resolveTemplateDocsPath());
|
|
556
577
|
const validationManifest = parseContractToolsManifest(await readFile(path.join(resolveTemplateValidationPath(), CONTRACT_TOOLS_MANIFEST_PATH)), 'FG-DOC-001');
|
package/dist/projectValidator.js
CHANGED
|
@@ -34,8 +34,8 @@ export const buildProjectValidatorEnvironment = (parentEnv) => ({
|
|
|
34
34
|
})),
|
|
35
35
|
});
|
|
36
36
|
// The `validate:funnel` script is byte-checked before this runs, so the CLI starts the same vite-node
|
|
37
|
-
// command itself. The managed runner
|
|
38
|
-
// shim
|
|
37
|
+
// command itself. The managed runner self-starts from argv[1], and runners before FUN-547 miss npm's
|
|
38
|
+
// Windows shim (`vite-node.mjs`), so the entry clears argv and calls it once, explicitly.
|
|
39
39
|
const validatorEntrySource = (runnerImport) => [
|
|
40
40
|
'process.argv.length = 1;',
|
|
41
41
|
`const { runValidateFunnelCli } = await import(${JSON.stringify(runnerImport)});`,
|
package/dist/selfUpdate.d.ts
CHANGED
|
@@ -5,11 +5,17 @@ export type CliInstallation = {
|
|
|
5
5
|
npmExecutablePath: string;
|
|
6
6
|
};
|
|
7
7
|
type RunCommand = (command: string, args: string[]) => Promise<void>;
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const npmInstallSpawn: (npmExecutablePath: string, args: readonly string[], platform?: NodeJS.Platform) => {
|
|
9
|
+
command: string;
|
|
10
|
+
args: string[];
|
|
11
|
+
shell: boolean;
|
|
12
|
+
};
|
|
13
|
+
export declare const deriveGlobalCliPrefix: (realExecutablePath: string, platform?: NodeJS.Platform) => string | null;
|
|
9
14
|
export declare const discoverCliInstallations: (input?: {
|
|
10
15
|
pathValue?: string;
|
|
11
16
|
entrypointPath?: string;
|
|
12
17
|
platform?: NodeJS.Platform;
|
|
18
|
+
nodeExecutablePath?: string;
|
|
13
19
|
realpathFn?: typeof realpath;
|
|
14
20
|
accessFn?: typeof access;
|
|
15
21
|
}) => Promise<CliInstallation[]>;
|
package/dist/selfUpdate.js
CHANGED
|
@@ -3,9 +3,15 @@ import { access, realpath } from 'node:fs/promises';
|
|
|
3
3
|
import { spawn } from 'node:child_process';
|
|
4
4
|
import path from 'node:path';
|
|
5
5
|
const CLI_PACKAGE = '@funnelsgrove/cli@latest';
|
|
6
|
+
const pathFor = (platform) => (platform === 'win32' ? path.win32 : path.posix);
|
|
7
|
+
// Node refuses to spawn .cmd files without a shell (EINVAL), and cmd.exe needs quoted paths.
|
|
8
|
+
export const npmInstallSpawn = (npmExecutablePath, args, platform = process.platform) => (platform === 'win32'
|
|
9
|
+
? { command: [npmExecutablePath, ...args].map((part) => `"${part}"`).join(' '), args: [], shell: true }
|
|
10
|
+
: { command: npmExecutablePath, args: [...args], shell: false });
|
|
6
11
|
const runCommandWithInheritedIo = async (command, args) => {
|
|
7
12
|
await new Promise((resolve, reject) => {
|
|
8
|
-
const
|
|
13
|
+
const npm = npmInstallSpawn(command, args);
|
|
14
|
+
const child = spawn(npm.command, npm.args, { shell: npm.shell, stdio: 'inherit' });
|
|
9
15
|
child.once('error', reject);
|
|
10
16
|
child.once('exit', (code, signal) => {
|
|
11
17
|
if (code === 0) {
|
|
@@ -18,24 +24,48 @@ const runCommandWithInheritedIo = async (command, args) => {
|
|
|
18
24
|
});
|
|
19
25
|
});
|
|
20
26
|
};
|
|
21
|
-
export const deriveGlobalCliPrefix = (realExecutablePath) => {
|
|
22
|
-
const
|
|
23
|
-
const
|
|
27
|
+
export const deriveGlobalCliPrefix = (realExecutablePath, platform = process.platform) => {
|
|
28
|
+
const { resolve, sep } = pathFor(platform);
|
|
29
|
+
const normalized = resolve(realExecutablePath);
|
|
30
|
+
const packageDir = `node_modules${sep}@funnelsgrove${sep}cli${sep}`;
|
|
31
|
+
const marker = platform === 'win32' ? `${sep}${packageDir}` : `${sep}lib${sep}${packageDir}`;
|
|
24
32
|
const markerIndex = normalized.indexOf(marker);
|
|
25
33
|
if (markerIndex < 1)
|
|
26
34
|
return null;
|
|
27
35
|
return normalized.slice(0, markerIndex);
|
|
28
36
|
};
|
|
37
|
+
// realpath of a Windows fgrove.cmd shim is the shim itself, so its directory is the candidate prefix.
|
|
38
|
+
const findWindowsPrefix = async (realExecutablePath, accessFn) => {
|
|
39
|
+
const fromPackagePath = deriveGlobalCliPrefix(realExecutablePath, 'win32');
|
|
40
|
+
if (fromPackagePath)
|
|
41
|
+
return fromPackagePath;
|
|
42
|
+
const prefix = path.win32.dirname(realExecutablePath);
|
|
43
|
+
await accessFn(path.win32.join(prefix, 'node_modules', '@funnelsgrove', 'cli', 'package.json'));
|
|
44
|
+
return prefix;
|
|
45
|
+
};
|
|
46
|
+
const firstAccessible = async (candidates, accessFn) => {
|
|
47
|
+
for (const candidate of candidates) {
|
|
48
|
+
try {
|
|
49
|
+
await accessFn(candidate, fsConstants.X_OK);
|
|
50
|
+
return candidate;
|
|
51
|
+
}
|
|
52
|
+
catch {
|
|
53
|
+
// Try the next location.
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
throw new Error('npm was not found.');
|
|
57
|
+
};
|
|
29
58
|
export const discoverCliInstallations = async (input = {}) => {
|
|
30
59
|
const platform = input.platform || process.platform;
|
|
60
|
+
const platformPath = pathFor(platform);
|
|
31
61
|
const realpathFn = input.realpathFn || realpath;
|
|
32
62
|
const accessFn = input.accessFn || access;
|
|
33
63
|
const executableName = platform === 'win32' ? 'fgrove.cmd' : 'fgrove';
|
|
34
64
|
const npmName = platform === 'win32' ? 'npm.cmd' : 'npm';
|
|
35
65
|
const candidates = (input.pathValue ?? process.env.PATH ?? '')
|
|
36
|
-
.split(
|
|
66
|
+
.split(platformPath.delimiter)
|
|
37
67
|
.filter(Boolean)
|
|
38
|
-
.map((directory) =>
|
|
68
|
+
.map((directory) => platformPath.join(directory, executableName));
|
|
39
69
|
if (input.entrypointPath)
|
|
40
70
|
candidates.push(input.entrypointPath);
|
|
41
71
|
const installations = new Map();
|
|
@@ -43,11 +73,26 @@ export const discoverCliInstallations = async (input = {}) => {
|
|
|
43
73
|
try {
|
|
44
74
|
await accessFn(candidate, fsConstants.X_OK);
|
|
45
75
|
const realExecutablePath = await realpathFn(candidate);
|
|
46
|
-
const prefix =
|
|
76
|
+
const prefix = platform === 'win32'
|
|
77
|
+
? await findWindowsPrefix(realExecutablePath, accessFn)
|
|
78
|
+
: deriveGlobalCliPrefix(realExecutablePath, platform);
|
|
47
79
|
if (!prefix || installations.has(prefix))
|
|
48
80
|
continue;
|
|
49
|
-
|
|
50
|
-
|
|
81
|
+
if (platform === 'win32') {
|
|
82
|
+
// Windows puts shims in the prefix itself; npm.cmd sits there (nvm-windows) or next to node.exe.
|
|
83
|
+
const npmExecutablePath = await firstAccessible([
|
|
84
|
+
platformPath.join(prefix, npmName),
|
|
85
|
+
platformPath.join(platformPath.dirname(input.nodeExecutablePath || process.execPath), npmName),
|
|
86
|
+
], accessFn);
|
|
87
|
+
installations.set(prefix, {
|
|
88
|
+
prefix,
|
|
89
|
+
executablePath: platformPath.join(prefix, executableName),
|
|
90
|
+
npmExecutablePath,
|
|
91
|
+
});
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
const executablePath = platformPath.join(prefix, 'bin', executableName);
|
|
95
|
+
const npmExecutablePath = platformPath.join(prefix, 'bin', npmName);
|
|
51
96
|
await accessFn(npmExecutablePath, fsConstants.X_OK);
|
|
52
97
|
installations.set(prefix, { prefix, executablePath, npmExecutablePath });
|
|
53
98
|
}
|
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
"minimumCliVersion": "0.1.20",
|
|
5
5
|
"entries": [
|
|
6
6
|
{
|
|
7
|
-
"repositoryCliVersion": "0.1.
|
|
7
|
+
"repositoryCliVersion": "0.1.389",
|
|
8
8
|
"manifest": {
|
|
9
9
|
"schemaVersion": 1,
|
|
10
|
-
"bundleVersion": "2.0.
|
|
10
|
+
"bundleVersion": "2.0.382",
|
|
11
11
|
"stepContractVersion": 3,
|
|
12
12
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
13
13
|
"managedFiles": [
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
{
|
|
47
47
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
48
|
-
"sha256": "
|
|
48
|
+
"sha256": "5bee507543f9e8b4bfe33f85be213b63cf9d00f0028d3561fe6dfd42b9e99205"
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
51
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -145,16 +145,16 @@
|
|
|
145
145
|
},
|
|
146
146
|
{
|
|
147
147
|
"path": "funnel-docs.config.json",
|
|
148
|
-
"sha256": "
|
|
148
|
+
"sha256": "42889ded15fee14db792363bfe7bdd5e6084486f5d69912e81fa965b1ddaee19"
|
|
149
149
|
}
|
|
150
150
|
]
|
|
151
151
|
}
|
|
152
152
|
},
|
|
153
153
|
{
|
|
154
|
-
"repositoryCliVersion": "0.1.
|
|
154
|
+
"repositoryCliVersion": "0.1.388",
|
|
155
155
|
"manifest": {
|
|
156
156
|
"schemaVersion": 1,
|
|
157
|
-
"bundleVersion": "2.0.
|
|
157
|
+
"bundleVersion": "2.0.381",
|
|
158
158
|
"stepContractVersion": 3,
|
|
159
159
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
160
160
|
"managedFiles": [
|
|
@@ -192,7 +192,7 @@
|
|
|
192
192
|
},
|
|
193
193
|
{
|
|
194
194
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
195
|
-
"sha256": "
|
|
195
|
+
"sha256": "bfb57e2f162ac699af453849b607c5f76e29b5b8d2a1d8137a40e67cb901f626"
|
|
196
196
|
},
|
|
197
197
|
{
|
|
198
198
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -292,16 +292,16 @@
|
|
|
292
292
|
},
|
|
293
293
|
{
|
|
294
294
|
"path": "funnel-docs.config.json",
|
|
295
|
-
"sha256": "
|
|
295
|
+
"sha256": "e644eb7e5bfa6cbba595b8971efd26edc213cfccac95f0ae5478ee261fec4869"
|
|
296
296
|
}
|
|
297
297
|
]
|
|
298
298
|
}
|
|
299
299
|
},
|
|
300
300
|
{
|
|
301
|
-
"repositoryCliVersion": "0.1.
|
|
301
|
+
"repositoryCliVersion": "0.1.387",
|
|
302
302
|
"manifest": {
|
|
303
303
|
"schemaVersion": 1,
|
|
304
|
-
"bundleVersion": "2.0.
|
|
304
|
+
"bundleVersion": "2.0.380",
|
|
305
305
|
"stepContractVersion": 3,
|
|
306
306
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
307
307
|
"managedFiles": [
|
|
@@ -339,7 +339,7 @@
|
|
|
339
339
|
},
|
|
340
340
|
{
|
|
341
341
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
342
|
-
"sha256": "
|
|
342
|
+
"sha256": "6190043bdb5b2b7ca2d3dfa35e7eef013732bb8d762b73f8d7de05f199ce43fb"
|
|
343
343
|
},
|
|
344
344
|
{
|
|
345
345
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -439,16 +439,16 @@
|
|
|
439
439
|
},
|
|
440
440
|
{
|
|
441
441
|
"path": "funnel-docs.config.json",
|
|
442
|
-
"sha256": "
|
|
442
|
+
"sha256": "510ffaf88f457b36dc6cbe8bcf2afba4b1ec0371b56ba70aa4e91d91c5965f03"
|
|
443
443
|
}
|
|
444
444
|
]
|
|
445
445
|
}
|
|
446
446
|
},
|
|
447
447
|
{
|
|
448
|
-
"repositoryCliVersion": "0.1.
|
|
448
|
+
"repositoryCliVersion": "0.1.386",
|
|
449
449
|
"manifest": {
|
|
450
450
|
"schemaVersion": 1,
|
|
451
|
-
"bundleVersion": "2.0.
|
|
451
|
+
"bundleVersion": "2.0.379",
|
|
452
452
|
"stepContractVersion": 3,
|
|
453
453
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
454
454
|
"managedFiles": [
|
|
@@ -486,7 +486,7 @@
|
|
|
486
486
|
},
|
|
487
487
|
{
|
|
488
488
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
489
|
-
"sha256": "
|
|
489
|
+
"sha256": "806815a4d9393db1977179b790c2480dae44e99f5b1a0fad0e2abb9a4a42ed12"
|
|
490
490
|
},
|
|
491
491
|
{
|
|
492
492
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -506,7 +506,7 @@
|
|
|
506
506
|
},
|
|
507
507
|
{
|
|
508
508
|
"path": "docs/funnelsgrove/recipes/add-experiment.md",
|
|
509
|
-
"sha256": "
|
|
509
|
+
"sha256": "4ffda52eecb6caaabe5ac45a1049e995065db983f98d844d256f2296bcfe9ce7"
|
|
510
510
|
},
|
|
511
511
|
{
|
|
512
512
|
"path": "docs/funnelsgrove/recipes/add-step.md",
|
|
@@ -586,16 +586,16 @@
|
|
|
586
586
|
},
|
|
587
587
|
{
|
|
588
588
|
"path": "funnel-docs.config.json",
|
|
589
|
-
"sha256": "
|
|
589
|
+
"sha256": "85c5912ad82f93ac73658b735b6b598b404305bcf3c18c60d3c000157eba3d58"
|
|
590
590
|
}
|
|
591
591
|
]
|
|
592
592
|
}
|
|
593
593
|
},
|
|
594
594
|
{
|
|
595
|
-
"repositoryCliVersion": "0.1.
|
|
595
|
+
"repositoryCliVersion": "0.1.385",
|
|
596
596
|
"manifest": {
|
|
597
597
|
"schemaVersion": 1,
|
|
598
|
-
"bundleVersion": "2.0.
|
|
598
|
+
"bundleVersion": "2.0.378",
|
|
599
599
|
"stepContractVersion": 3,
|
|
600
600
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
601
601
|
"managedFiles": [
|
|
@@ -633,7 +633,7 @@
|
|
|
633
633
|
},
|
|
634
634
|
{
|
|
635
635
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
636
|
-
"sha256": "
|
|
636
|
+
"sha256": "5c256aedf9279b598e1289493ee5c69beb8ba7c12ee645d1f4b96642c245a233"
|
|
637
637
|
},
|
|
638
638
|
{
|
|
639
639
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -653,7 +653,7 @@
|
|
|
653
653
|
},
|
|
654
654
|
{
|
|
655
655
|
"path": "docs/funnelsgrove/recipes/add-experiment.md",
|
|
656
|
-
"sha256": "
|
|
656
|
+
"sha256": "4ffda52eecb6caaabe5ac45a1049e995065db983f98d844d256f2296bcfe9ce7"
|
|
657
657
|
},
|
|
658
658
|
{
|
|
659
659
|
"path": "docs/funnelsgrove/recipes/add-step.md",
|
|
@@ -733,16 +733,16 @@
|
|
|
733
733
|
},
|
|
734
734
|
{
|
|
735
735
|
"path": "funnel-docs.config.json",
|
|
736
|
-
"sha256": "
|
|
736
|
+
"sha256": "3bc93d3697c4ba731a8c632285156e7a50ddef952e70a152e0bc405c76f340b7"
|
|
737
737
|
}
|
|
738
738
|
]
|
|
739
739
|
}
|
|
740
740
|
},
|
|
741
741
|
{
|
|
742
|
-
"repositoryCliVersion": "0.1.
|
|
742
|
+
"repositoryCliVersion": "0.1.384",
|
|
743
743
|
"manifest": {
|
|
744
744
|
"schemaVersion": 1,
|
|
745
|
-
"bundleVersion": "2.0.
|
|
745
|
+
"bundleVersion": "2.0.377",
|
|
746
746
|
"stepContractVersion": 3,
|
|
747
747
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
748
748
|
"managedFiles": [
|
|
@@ -780,7 +780,7 @@
|
|
|
780
780
|
},
|
|
781
781
|
{
|
|
782
782
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
783
|
-
"sha256": "
|
|
783
|
+
"sha256": "5890c665af845196bdc73985e504af850caf1d7f67f10d87afa5f49c8b503961"
|
|
784
784
|
},
|
|
785
785
|
{
|
|
786
786
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -800,7 +800,7 @@
|
|
|
800
800
|
},
|
|
801
801
|
{
|
|
802
802
|
"path": "docs/funnelsgrove/recipes/add-experiment.md",
|
|
803
|
-
"sha256": "
|
|
803
|
+
"sha256": "4ffda52eecb6caaabe5ac45a1049e995065db983f98d844d256f2296bcfe9ce7"
|
|
804
804
|
},
|
|
805
805
|
{
|
|
806
806
|
"path": "docs/funnelsgrove/recipes/add-step.md",
|
|
@@ -880,16 +880,16 @@
|
|
|
880
880
|
},
|
|
881
881
|
{
|
|
882
882
|
"path": "funnel-docs.config.json",
|
|
883
|
-
"sha256": "
|
|
883
|
+
"sha256": "1d7cbc72cd78b0c50307917b6b3ab067aa9ef769323489e0094e81b7f93c4d61"
|
|
884
884
|
}
|
|
885
885
|
]
|
|
886
886
|
}
|
|
887
887
|
},
|
|
888
888
|
{
|
|
889
|
-
"repositoryCliVersion": "0.1.
|
|
889
|
+
"repositoryCliVersion": "0.1.383",
|
|
890
890
|
"manifest": {
|
|
891
891
|
"schemaVersion": 1,
|
|
892
|
-
"bundleVersion": "2.0.
|
|
892
|
+
"bundleVersion": "2.0.376",
|
|
893
893
|
"stepContractVersion": 3,
|
|
894
894
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
895
895
|
"managedFiles": [
|
|
@@ -927,7 +927,7 @@
|
|
|
927
927
|
},
|
|
928
928
|
{
|
|
929
929
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
930
|
-
"sha256": "
|
|
930
|
+
"sha256": "8baf2af97abca602260c12cd60e4a84756eadefe1d317336f8d5b6625fc3a8a2"
|
|
931
931
|
},
|
|
932
932
|
{
|
|
933
933
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -1027,7 +1027,7 @@
|
|
|
1027
1027
|
},
|
|
1028
1028
|
{
|
|
1029
1029
|
"path": "funnel-docs.config.json",
|
|
1030
|
-
"sha256": "
|
|
1030
|
+
"sha256": "7e635ec7551e08724a57b95cf6358ae5cd79576acf7ccfd81aae889ce4930a91"
|
|
1031
1031
|
}
|
|
1032
1032
|
]
|
|
1033
1033
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"bundleVersion": "2.0.
|
|
3
|
+
"bundleVersion": "2.0.382",
|
|
4
4
|
"stepContractVersion": 3,
|
|
5
5
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
6
6
|
"managedFiles": [
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
40
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
41
|
-
"sha256": "
|
|
41
|
+
"sha256": "5bee507543f9e8b4bfe33f85be213b63cf9d00f0028d3561fe6dfd42b9e99205"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
},
|
|
139
139
|
{
|
|
140
140
|
"path": "funnel-docs.config.json",
|
|
141
|
-
"sha256": "
|
|
141
|
+
"sha256": "42889ded15fee14db792363bfe7bdd5e6084486f5d69912e81fa965b1ddaee19"
|
|
142
142
|
}
|
|
143
143
|
]
|
|
144
144
|
}
|
|
@@ -17,7 +17,7 @@ Supported read versions: `1`, `2`, `3`. Authoring and publish target version `3`
|
|
|
17
17
|
|
|
18
18
|
### Package release order
|
|
19
19
|
|
|
20
|
-
Release `@funnelsgrove/sdk` `0.
|
|
20
|
+
Release `@funnelsgrove/sdk` `0.5.0` first, then `@funnelsgrove/runtime` `0.48.0`, then `@funnelsgrove/analytics` `0.31.0`, then `@funnelsgrove/payments` `0.77.0`. The production deploy verifies the zero-traffic API candidate, publishes and verifies `@funnelsgrove/cli` `0.1.389`, and only then promotes the candidate to production traffic. The serving API must never advertise an unpublished preferred CLI. Publishing packages and deploying production remain separately approved operational actions.
|
|
21
21
|
<!-- funnelsgrove:generated:end contract-v3/migration/step-contract-v3 -->
|
|
22
22
|
|
|
23
23
|
## Version-last policy
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"bundleVersion": "2.0.
|
|
3
|
+
"bundleVersion": "2.0.382",
|
|
4
4
|
"stepContractVersion": 3,
|
|
5
5
|
"contractHash": "d761e91d5ac6ff9e72c6d49c5bcd014270912473a66f99c49d726c65998085cf",
|
|
6
6
|
"managedFiles": [
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
40
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
41
|
-
"sha256": "
|
|
41
|
+
"sha256": "5bee507543f9e8b4bfe33f85be213b63cf9d00f0028d3561fe6dfd42b9e99205"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
"path": "docs/funnelsgrove/qa/analytics.md",
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
},
|
|
139
139
|
{
|
|
140
140
|
"path": "funnel-docs.config.json",
|
|
141
|
-
"sha256": "
|
|
141
|
+
"sha256": "42889ded15fee14db792363bfe7bdd5e6084486f5d69912e81fa965b1ddaee19"
|
|
142
142
|
}
|
|
143
143
|
]
|
|
144
144
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"sourceTreeHash": "
|
|
3
|
+
"sourceTreeHash": "c1dca39e2e7385328da39ba6992c47600f02197e54730f0b6f21e7379346d01c",
|
|
4
4
|
"stepContractVersion": 3,
|
|
5
|
-
"docsBundleVersion": "2.0.
|
|
5
|
+
"docsBundleVersion": "2.0.382",
|
|
6
6
|
"files": [
|
|
7
7
|
{
|
|
8
8
|
"path": ".env.example",
|
|
@@ -11,12 +11,12 @@
|
|
|
11
11
|
},
|
|
12
12
|
{
|
|
13
13
|
"path": ".funnelsgrove-contract-tools.json",
|
|
14
|
-
"sha256": "
|
|
14
|
+
"sha256": "7a51569698a5d7a738766161efa527b581a3c547fd7a329cfc8762d9a5ccc4ac",
|
|
15
15
|
"mode": "100644"
|
|
16
16
|
},
|
|
17
17
|
{
|
|
18
18
|
"path": ".funnelsgrove-docs.json",
|
|
19
|
-
"sha256": "
|
|
19
|
+
"sha256": "05dda7c9ad27d151bfbf63dbcf6b3563c0180449de12480b0bba047bcfc06d8d",
|
|
20
20
|
"mode": "100644"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
78
|
"path": "docs/funnelsgrove/migrations/step-contract-v3.md",
|
|
79
|
-
"sha256": "
|
|
79
|
+
"sha256": "5bee507543f9e8b4bfe33f85be213b63cf9d00f0028d3561fe6dfd42b9e99205",
|
|
80
80
|
"mode": "100644"
|
|
81
81
|
},
|
|
82
82
|
{
|
|
@@ -206,7 +206,7 @@
|
|
|
206
206
|
},
|
|
207
207
|
{
|
|
208
208
|
"path": "funnel-docs.config.json",
|
|
209
|
-
"sha256": "
|
|
209
|
+
"sha256": "42889ded15fee14db792363bfe7bdd5e6084486f5d69912e81fa965b1ddaee19",
|
|
210
210
|
"mode": "100644"
|
|
211
211
|
},
|
|
212
212
|
{
|
|
@@ -431,7 +431,7 @@
|
|
|
431
431
|
},
|
|
432
432
|
{
|
|
433
433
|
"path": "src/contract/validate-funnel.cli.ts",
|
|
434
|
-
"sha256": "
|
|
434
|
+
"sha256": "d6f54999c95c9b08f3aed52657248736b59778609d3f79b86b08d1ed90fd5e17",
|
|
435
435
|
"mode": "100644"
|
|
436
436
|
},
|
|
437
437
|
{
|
|
@@ -17,7 +17,7 @@ Supported read versions: `1`, `2`, `3`. Authoring and publish target version `3`
|
|
|
17
17
|
|
|
18
18
|
### Package release order
|
|
19
19
|
|
|
20
|
-
Release `@funnelsgrove/sdk` `0.
|
|
20
|
+
Release `@funnelsgrove/sdk` `0.5.0` first, then `@funnelsgrove/runtime` `0.48.0`, then `@funnelsgrove/analytics` `0.31.0`, then `@funnelsgrove/payments` `0.77.0`. The production deploy verifies the zero-traffic API candidate, publishes and verifies `@funnelsgrove/cli` `0.1.389`, and only then promotes the candidate to production traffic. The serving API must never advertise an unpublished preferred CLI. Publishing packages and deploying production remain separately approved operational actions.
|
|
21
21
|
<!-- funnelsgrove:generated:end contract-v3/migration/step-contract-v3 -->
|
|
22
22
|
|
|
23
23
|
## Version-last policy
|
|
@@ -190,7 +190,9 @@ export const runValidateFunnelCli = async (
|
|
|
190
190
|
|
|
191
191
|
const isCliEntrypoint = (argv: readonly string[], modulePath: string): boolean => {
|
|
192
192
|
const resolvedModulePath = path.resolve(modulePath);
|
|
193
|
-
|
|
193
|
+
const entry = path.basename(argv[1] ?? '');
|
|
194
|
+
return entry === 'vite-node'
|
|
195
|
+
|| entry === 'vite-node.mjs'
|
|
194
196
|
|| argv.slice(1).some((argument) => path.resolve(argument) === resolvedModulePath);
|
|
195
197
|
};
|
|
196
198
|
|
|
@@ -190,7 +190,9 @@ export const runValidateFunnelCli = async (
|
|
|
190
190
|
|
|
191
191
|
const isCliEntrypoint = (argv: readonly string[], modulePath: string): boolean => {
|
|
192
192
|
const resolvedModulePath = path.resolve(modulePath);
|
|
193
|
-
|
|
193
|
+
const entry = path.basename(argv[1] ?? '');
|
|
194
|
+
return entry === 'vite-node'
|
|
195
|
+
|| entry === 'vite-node.mjs'
|
|
194
196
|
|| argv.slice(1).some((argument) => path.resolve(argument) === resolvedModulePath);
|
|
195
197
|
};
|
|
196
198
|
|