@telorun/analyzer 0.72.0 → 0.73.0
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/analyzer.d.ts.map +1 -1
- package/dist/analyzer.js +50 -13
- package/dist/builtins.d.ts.map +1 -1
- package/dist/builtins.js +71 -97
- package/dist/cel-scope-query.d.ts.map +1 -1
- package/dist/cel-scope-query.js +32 -11
- package/dist/cel-scope.d.ts.map +1 -1
- package/dist/cel-scope.js +1 -0
- package/dist/eval-paths.d.ts +36 -5
- package/dist/eval-paths.d.ts.map +1 -1
- package/dist/eval-paths.js +47 -6
- package/dist/extends-resolution.d.ts +12 -0
- package/dist/extends-resolution.d.ts.map +1 -1
- package/dist/extends-resolution.js +23 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/nearest-name.d.ts +22 -0
- package/dist/nearest-name.d.ts.map +1 -0
- package/dist/nearest-name.js +43 -0
- package/dist/release/destinations.d.ts +59 -0
- package/dist/release/destinations.d.ts.map +1 -0
- package/dist/release/destinations.js +75 -0
- package/dist/release/index.d.ts +6 -2
- package/dist/release/index.d.ts.map +1 -1
- package/dist/release/index.js +3 -1
- package/dist/release/ledger.d.ts +20 -11
- package/dist/release/ledger.d.ts.map +1 -1
- package/dist/release/ledger.js +43 -14
- package/dist/release/release-plan.d.ts +3 -2
- package/dist/release/release-plan.d.ts.map +1 -1
- package/dist/release/release-plan.js +12 -19
- package/dist/release/workspace-config.d.ts +114 -34
- package/dist/release/workspace-config.d.ts.map +1 -1
- package/dist/release/workspace-config.js +322 -38
- package/dist/release/workspace-schema.d.ts +41 -0
- package/dist/release/workspace-schema.d.ts.map +1 -0
- package/dist/release/workspace-schema.js +77 -0
- package/dist/schema-error-report.d.ts +7 -0
- package/dist/schema-error-report.d.ts.map +1 -1
- package/dist/schema-error-report.js +9 -4
- package/dist/telo-version.d.ts +1 -1
- package/dist/telo-version.js +1 -1
- package/dist/template-body.d.ts +10 -0
- package/dist/template-body.d.ts.map +1 -1
- package/dist/template-body.js +25 -0
- package/dist/validate-cel-context.d.ts +23 -8
- package/dist/validate-cel-context.d.ts.map +1 -1
- package/dist/validate-cel-context.js +48 -16
- package/dist/validate-exports.d.ts +28 -0
- package/dist/validate-exports.d.ts.map +1 -0
- package/dist/validate-exports.js +146 -0
- package/dist/validate-extends.d.ts.map +1 -1
- package/dist/validate-extends.js +37 -1
- package/dist/validate-provider-coherence.d.ts +4 -8
- package/dist/validate-provider-coherence.d.ts.map +1 -1
- package/dist/validate-provider-coherence.js +12 -123
- package/dist/validate-references.d.ts.map +1 -1
- package/dist/validate-references.js +141 -60
- package/dist/validate-template-body.d.ts +36 -0
- package/dist/validate-template-body.d.ts.map +1 -0
- package/dist/validate-template-body.js +246 -0
- package/package.json +3 -2
- package/src/analyzer.ts +64 -11
- package/src/builtins.ts +85 -97
- package/src/cel-scope-query.ts +28 -9
- package/src/cel-scope.ts +1 -0
- package/src/eval-paths.ts +53 -6
- package/src/extends-resolution.ts +24 -0
- package/src/index.ts +1 -0
- package/src/nearest-name.ts +47 -0
- package/src/release/destinations.ts +105 -0
- package/src/release/index.ts +33 -2
- package/src/release/ledger.ts +51 -21
- package/src/release/release-plan.ts +16 -26
- package/src/release/workspace-config.ts +483 -47
- package/src/release/workspace-schema.ts +99 -0
- package/src/schema-error-report.ts +16 -4
- package/src/telo-version.ts +1 -1
- package/src/template-body.ts +25 -0
- package/src/validate-cel-context.ts +57 -16
- package/src/validate-exports.ts +185 -0
- package/src/validate-extends.ts +43 -0
- package/src/validate-provider-coherence.ts +17 -127
- package/src/validate-references.ts +141 -60
- package/src/validate-template-body.ts +274 -0
- package/dist/validate-template-dispatch.d.ts +0 -27
- package/dist/validate-template-dispatch.d.ts.map +0 -1
- package/dist/validate-template-dispatch.js +0 -95
- package/src/validate-template-dispatch.ts +0 -99
|
@@ -80,6 +80,29 @@ export function effectiveAuthorSchema(def, resolve) {
|
|
|
80
80
|
const parentSchema = effectiveAuthorSchema(parent, resolve);
|
|
81
81
|
return mergeTypeSchemas([parentSchema, own]);
|
|
82
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* The parent's required fields that a merge-form child leaves on its OWN author
|
|
85
|
+
* surface — inherited by the rule above, and not redeclared by the child.
|
|
86
|
+
*
|
|
87
|
+
* The one fact behind a confusing diagnostic: a kind written to wire a field
|
|
88
|
+
* internally still demands it from its consumer, because without `base:` the
|
|
89
|
+
* child is authored against merge(parent, own) and the parent's `required` comes
|
|
90
|
+
* along. Empty for a child with `base:` (its surface is its own schema) and for
|
|
91
|
+
* a kind that extends nothing, so a caller can use a non-empty result as the
|
|
92
|
+
* condition itself.
|
|
93
|
+
*/
|
|
94
|
+
export function inheritedRequiredFields(def, resolve) {
|
|
95
|
+
if (!body(def).extends || body(def).base)
|
|
96
|
+
return [];
|
|
97
|
+
const parent = resolveParent(def, resolve);
|
|
98
|
+
if (!parent)
|
|
99
|
+
return [];
|
|
100
|
+
const required = effectiveAuthorSchema(parent, resolve).required;
|
|
101
|
+
if (!Array.isArray(required))
|
|
102
|
+
return [];
|
|
103
|
+
const own = ((body(def).schema ?? {}).properties ?? {});
|
|
104
|
+
return required.filter((f) => typeof f === "string" && !(f in own));
|
|
105
|
+
}
|
|
83
106
|
/**
|
|
84
107
|
* The fields a merge-form inheriting child publishes over its parent's reading.
|
|
85
108
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ export { StaticAnalyzer } from "./analyzer.js";
|
|
|
4
4
|
export { importResolutionDiagnostics } from "./import-resolution-diagnostics.js";
|
|
5
5
|
export type { GraphLoadError, ImportEdge, LoadedFile, LoadedGraph, LoadedModule, ParseError, } from "./loaded-types.js";
|
|
6
6
|
export { collectModuleDocuments, flattenForAnalyzer, flattenLoadedModule, forwardReExportManifests, parseExportEntry, reExportSpecsFromExports, resolveExportedKinds, selectModuleManifestsForAnalysis, stampExportedKinds, stampReExportedKinds, stampRequiredResources, stampResolvedSource, stampSharedLifecycle, type ParsedExportEntry, type ReExportSpec, } from "./flatten-for-analyzer.js";
|
|
7
|
-
export { buildEvalPaths, celEvalModeAt, celEvalSites, declaresCelRegion, evalPathCovers, mergeCelEvalSites, pathMatchesScope, NO_CEL_EVAL_SITES, } from "./eval-paths.js";
|
|
7
|
+
export { buildEvalPaths, celEvalModeAt, celEvalSites, declaresCelRegion, evalPathCovers, implicitEvalSites, mergeCelEvalSites, pathMatchesScope, NO_CEL_EVAL_SITES, } from "./eval-paths.js";
|
|
8
8
|
export type { CelEvalSites } from "./eval-paths.js";
|
|
9
9
|
export { injectedDeclarations, isInjectedDeclaration, readLibraryLifecycle, readResourceInputs, readSuppliedResources, } from "./resource-input.js";
|
|
10
10
|
export type { LibraryLifecycle, ResourceInput } from "./resource-input.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,YAAY,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAC;AACjF,YAAY,EACR,cAAc,EACd,UAAU,EACV,UAAU,EACV,WAAW,EACX,YAAY,EACZ,UAAU,GACb,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACH,sBAAsB,EACtB,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACxB,gBAAgB,EAChB,wBAAwB,EACxB,oBAAoB,EACpB,gCAAgC,EAChC,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,mBAAmB,EACnB,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,KAAK,YAAY,GACpB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,cAAc,EACd,aAAa,EACb,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M,EAAE,MAAM,eAAe,CAAC;AAC9F,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC3E,YAAY,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAKxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,YAAY,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAC3E,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,YAAY,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAGzF,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,YAAY,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EACL,yBAAyB,EACzB,kBAAkB,EAClB,aAAa,EACb,aAAa,GACd,MAAM,YAAY,CAAC;AACpB,YAAY,EACR,kBAAkB,EAClB,eAAe,EACf,cAAc,EACd,aAAa,EACb,iBAAiB,EACjB,WAAW,EACX,cAAc,EACd,QAAQ,EACR,aAAa,EACb,KAAK,EACR,MAAM,YAAY,CAAC;AACpB,cAAc,uBAAuB,CAAC;AAGtC,cAAc,sBAAsB,CAAC;AAIrC,OAAO,EACL,uBAAuB,EACvB,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AACpC,cAAc,oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@ export { AnalysisRegistry } from "./analysis-registry.js";
|
|
|
2
2
|
export { StaticAnalyzer } from "./analyzer.js";
|
|
3
3
|
export { importResolutionDiagnostics } from "./import-resolution-diagnostics.js";
|
|
4
4
|
export { collectModuleDocuments, flattenForAnalyzer, flattenLoadedModule, forwardReExportManifests, parseExportEntry, reExportSpecsFromExports, resolveExportedKinds, selectModuleManifestsForAnalysis, stampExportedKinds, stampReExportedKinds, stampRequiredResources, stampResolvedSource, stampSharedLifecycle, } from "./flatten-for-analyzer.js";
|
|
5
|
-
export { buildEvalPaths, celEvalModeAt, celEvalSites, declaresCelRegion, evalPathCovers, mergeCelEvalSites, pathMatchesScope, NO_CEL_EVAL_SITES, } from "./eval-paths.js";
|
|
5
|
+
export { buildEvalPaths, celEvalModeAt, celEvalSites, declaresCelRegion, evalPathCovers, implicitEvalSites, mergeCelEvalSites, pathMatchesScope, NO_CEL_EVAL_SITES, } from "./eval-paths.js";
|
|
6
6
|
export { injectedDeclarations, isInjectedDeclaration, readLibraryLifecycle, readResourceInputs, readSuppliedResources, } from "./resource-input.js";
|
|
7
7
|
export { BINDINGS_ANNOTATION, bindingContextProperties, bindingDependencies, findBindingSites, resolveBindingOrder, } from "./cel-bindings.js";
|
|
8
8
|
export { CEL_RESERVED_WORDS, TYPE_LEVEL_DOC_KINDS, checkName, } from "./identifier-name.js";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THE closest candidate to a misspelled name, or undefined.
|
|
3
|
+
*
|
|
4
|
+
* One rule, because a suggestion here is emitted as a `DiagnosticFix` — a
|
|
5
|
+
* whole-value replacement an editor applies in one click — so "closest" has to
|
|
6
|
+
* mean the same thing wherever it is offered. Two properties carry that:
|
|
7
|
+
*
|
|
8
|
+
* - **A TIE returns undefined.** Two candidates at equal distance make the pick
|
|
9
|
+
* arbitrary, and an arbitrary pick that is one click from being applied is
|
|
10
|
+
* worse than no suggestion: it resolves by whatever order the candidate set
|
|
11
|
+
* happened to be built in, which is a `Set`'s insertion order.
|
|
12
|
+
* - **The threshold scales but is CAPPED** (`min(3, len/3)`, and nothing under
|
|
13
|
+
* 1). Without the cap a long name accepts a distant match; without the floor
|
|
14
|
+
* a two-character name gets a "correction" sharing nothing with it.
|
|
15
|
+
*
|
|
16
|
+
* Both are `computeSuggestKind`'s rule, lifted here so the kind-suggestion, the
|
|
17
|
+
* template-body and the export checks cannot drift into three answers — which
|
|
18
|
+
* they had, two of them byte-identical copies differing from this one in both
|
|
19
|
+
* properties.
|
|
20
|
+
*/
|
|
21
|
+
export declare function nearestName(target: string, candidates: Iterable<string>): string | undefined;
|
|
22
|
+
//# sourceMappingURL=nearest-name.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nearest-name.d.ts","sourceRoot":"","sources":["../src/nearest-name.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,QAAQ,CAAC,MAAM,CAAC,GAC3B,MAAM,GAAG,SAAS,CAqBpB"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { distance } from "./levenshtein.js";
|
|
2
|
+
/**
|
|
3
|
+
* THE closest candidate to a misspelled name, or undefined.
|
|
4
|
+
*
|
|
5
|
+
* One rule, because a suggestion here is emitted as a `DiagnosticFix` — a
|
|
6
|
+
* whole-value replacement an editor applies in one click — so "closest" has to
|
|
7
|
+
* mean the same thing wherever it is offered. Two properties carry that:
|
|
8
|
+
*
|
|
9
|
+
* - **A TIE returns undefined.** Two candidates at equal distance make the pick
|
|
10
|
+
* arbitrary, and an arbitrary pick that is one click from being applied is
|
|
11
|
+
* worse than no suggestion: it resolves by whatever order the candidate set
|
|
12
|
+
* happened to be built in, which is a `Set`'s insertion order.
|
|
13
|
+
* - **The threshold scales but is CAPPED** (`min(3, len/3)`, and nothing under
|
|
14
|
+
* 1). Without the cap a long name accepts a distant match; without the floor
|
|
15
|
+
* a two-character name gets a "correction" sharing nothing with it.
|
|
16
|
+
*
|
|
17
|
+
* Both are `computeSuggestKind`'s rule, lifted here so the kind-suggestion, the
|
|
18
|
+
* template-body and the export checks cannot drift into three answers — which
|
|
19
|
+
* they had, two of them byte-identical copies differing from this one in both
|
|
20
|
+
* properties.
|
|
21
|
+
*/
|
|
22
|
+
export function nearestName(target, candidates) {
|
|
23
|
+
if (!target)
|
|
24
|
+
return undefined;
|
|
25
|
+
const threshold = Math.min(3, Math.floor(target.length / 3));
|
|
26
|
+
if (threshold < 1)
|
|
27
|
+
return undefined;
|
|
28
|
+
let best;
|
|
29
|
+
let bestDist = threshold + 1;
|
|
30
|
+
let tied = false;
|
|
31
|
+
for (const candidate of candidates) {
|
|
32
|
+
const d = distance(target, candidate);
|
|
33
|
+
if (d < bestDist) {
|
|
34
|
+
best = candidate;
|
|
35
|
+
bestDist = d;
|
|
36
|
+
tied = false;
|
|
37
|
+
}
|
|
38
|
+
else if (d === bestDist) {
|
|
39
|
+
tied = true;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
return !best || bestDist > threshold || tied ? undefined : best;
|
|
43
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Where each module publishes, and the two ways a set of destinations can be
|
|
3
|
+
* inconsistent.
|
|
4
|
+
*
|
|
5
|
+
* A destination is the module's resolved registry base plus its own directory
|
|
6
|
+
* name. That rule held silently for as long as every module sat at one depth
|
|
7
|
+
* under one base with a unique directory name; per-subtree bases remove that
|
|
8
|
+
* coincidence, so both failures it was hiding become reachable and are checked
|
|
9
|
+
* here — **at plan time, before any payload is built**, because the payload
|
|
10
|
+
* builder's own refusal speaks about a manifest published to two places rather
|
|
11
|
+
* than about the workspace file that said so.
|
|
12
|
+
*
|
|
13
|
+
* Pure data in, diagnostics out: the destinations are already computed for
|
|
14
|
+
* `telo release order`, so one derivation feeds that payload and both checks.
|
|
15
|
+
*/
|
|
16
|
+
import type { ModuleKey } from "./fragment.js";
|
|
17
|
+
import type { ReleaseDiagnostic } from "./release-plan.js";
|
|
18
|
+
export interface ModuleDestination {
|
|
19
|
+
readonly key: ModuleKey;
|
|
20
|
+
/** `<registry>/<the module's own directory name>`. */
|
|
21
|
+
readonly destination: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* A relative import between two workspace modules, with both answers about
|
|
25
|
+
* where the target publishes.
|
|
26
|
+
*
|
|
27
|
+
* `derived` is what the importer's own destination yields when the import path
|
|
28
|
+
* is applied to it — the transport's rule, and what ref canonicalization writes
|
|
29
|
+
* into the published manifest. `assigned` is what discovery independently gives
|
|
30
|
+
* that module.
|
|
31
|
+
*/
|
|
32
|
+
export interface ImportDestination {
|
|
33
|
+
readonly from: ModuleKey;
|
|
34
|
+
readonly to: ModuleKey;
|
|
35
|
+
readonly derived: string;
|
|
36
|
+
readonly assigned: string;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Two modules must not resolve to one ref.
|
|
40
|
+
*
|
|
41
|
+
* Nothing else catches it: the payload builder is keyed by manifest, so it sees
|
|
42
|
+
* one module claimed by two destinations and never two modules claiming one,
|
|
43
|
+
* while the ledger keys by module — both entries would record digests for a
|
|
44
|
+
* single published artifact and reconciliation could never settle.
|
|
45
|
+
*/
|
|
46
|
+
export declare function checkDestinationCollisions(destinations: readonly ModuleDestination[]): ReleaseDiagnostic[];
|
|
47
|
+
/**
|
|
48
|
+
* A relative import is valid only where the importer's derived ref for its
|
|
49
|
+
* target equals the destination that module is independently assigned.
|
|
50
|
+
*
|
|
51
|
+
* Equal registries are necessary and not sufficient — two modules under one base
|
|
52
|
+
* at different directory depths derive differently too. Making the builder take
|
|
53
|
+
* the assigned destination instead is not the fix: it would put a ref in the
|
|
54
|
+
* artifact that the transport's resolution rule does not produce, so the
|
|
55
|
+
* manifest would say one thing and every consumer resolving relatively would
|
|
56
|
+
* compute another.
|
|
57
|
+
*/
|
|
58
|
+
export declare function checkImportDestinations(edges: readonly ImportDestination[]): ReleaseDiagnostic[];
|
|
59
|
+
//# sourceMappingURL=destinations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"destinations.d.ts","sourceRoot":"","sources":["../../src/release/destinations.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAE3D,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,GAAG,EAAE,SAAS,CAAC;IACxB,sDAAsD;IACtD,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;CAC9B;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC;IACzB,QAAQ,CAAC,EAAE,EAAE,SAAS,CAAC;IACvB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAED;;;;;;;GAOG;AACH,wBAAgB,0BAA0B,CACxC,YAAY,EAAE,SAAS,iBAAiB,EAAE,GACzC,iBAAiB,EAAE,CAsBrB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,SAAS,iBAAiB,EAAE,GAClC,iBAAiB,EAAE,CAgBrB"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Where each module publishes, and the two ways a set of destinations can be
|
|
3
|
+
* inconsistent.
|
|
4
|
+
*
|
|
5
|
+
* A destination is the module's resolved registry base plus its own directory
|
|
6
|
+
* name. That rule held silently for as long as every module sat at one depth
|
|
7
|
+
* under one base with a unique directory name; per-subtree bases remove that
|
|
8
|
+
* coincidence, so both failures it was hiding become reachable and are checked
|
|
9
|
+
* here — **at plan time, before any payload is built**, because the payload
|
|
10
|
+
* builder's own refusal speaks about a manifest published to two places rather
|
|
11
|
+
* than about the workspace file that said so.
|
|
12
|
+
*
|
|
13
|
+
* Pure data in, diagnostics out: the destinations are already computed for
|
|
14
|
+
* `telo release order`, so one derivation feeds that payload and both checks.
|
|
15
|
+
*/
|
|
16
|
+
/**
|
|
17
|
+
* Two modules must not resolve to one ref.
|
|
18
|
+
*
|
|
19
|
+
* Nothing else catches it: the payload builder is keyed by manifest, so it sees
|
|
20
|
+
* one module claimed by two destinations and never two modules claiming one,
|
|
21
|
+
* while the ledger keys by module — both entries would record digests for a
|
|
22
|
+
* single published artifact and reconciliation could never settle.
|
|
23
|
+
*/
|
|
24
|
+
export function checkDestinationCollisions(destinations) {
|
|
25
|
+
const byDestination = new Map();
|
|
26
|
+
for (const { key, destination } of destinations) {
|
|
27
|
+
const sharing = byDestination.get(destination);
|
|
28
|
+
if (sharing)
|
|
29
|
+
sharing.push(key);
|
|
30
|
+
else
|
|
31
|
+
byDestination.set(destination, [key]);
|
|
32
|
+
}
|
|
33
|
+
const diagnostics = [];
|
|
34
|
+
for (const [destination, keys] of byDestination) {
|
|
35
|
+
if (keys.length < 2)
|
|
36
|
+
continue;
|
|
37
|
+
diagnostics.push({
|
|
38
|
+
severity: "error",
|
|
39
|
+
code: "DESTINATION_COLLISION",
|
|
40
|
+
message: `${keys.sort().join(" and ")} both publish to '${destination}'. A module's ref is its ` +
|
|
41
|
+
`registry base plus its own directory name, so they would overwrite one artifact and ` +
|
|
42
|
+
`their ledger entries could never reconcile. Rename one directory, or give one of the ` +
|
|
43
|
+
`subtrees its own 'registry:' in telo-workspace.yaml.`,
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
return diagnostics;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* A relative import is valid only where the importer's derived ref for its
|
|
50
|
+
* target equals the destination that module is independently assigned.
|
|
51
|
+
*
|
|
52
|
+
* Equal registries are necessary and not sufficient — two modules under one base
|
|
53
|
+
* at different directory depths derive differently too. Making the builder take
|
|
54
|
+
* the assigned destination instead is not the fix: it would put a ref in the
|
|
55
|
+
* artifact that the transport's resolution rule does not produce, so the
|
|
56
|
+
* manifest would say one thing and every consumer resolving relatively would
|
|
57
|
+
* compute another.
|
|
58
|
+
*/
|
|
59
|
+
export function checkImportDestinations(edges) {
|
|
60
|
+
const diagnostics = [];
|
|
61
|
+
for (const edge of edges) {
|
|
62
|
+
if (edge.derived === edge.assigned)
|
|
63
|
+
continue;
|
|
64
|
+
diagnostics.push({
|
|
65
|
+
severity: "error",
|
|
66
|
+
code: "IMPORT_DESTINATION_CONFLICT",
|
|
67
|
+
message: `${edge.from} imports ${edge.to} by relative path, which canonicalizes to ` +
|
|
68
|
+
`'${edge.derived}' — but ${edge.to} publishes to '${edge.assigned}'. Publishing rewrites ` +
|
|
69
|
+
`the import to the ref its own path yields, so the artifact would name a module nobody ` +
|
|
70
|
+
`pushes. Give the two the same registry base and the same directory depth, or make it a ` +
|
|
71
|
+
`pinned remote import, which is what a dependency across a publish boundary is.`,
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
return diagnostics;
|
|
75
|
+
}
|
package/dist/release/index.d.ts
CHANGED
|
@@ -21,6 +21,10 @@ export type { LayerChange, LayerDigests } from "./payload-digest.js";
|
|
|
21
21
|
export { orderByImports, planRelease } from "./release-plan.js";
|
|
22
22
|
export type { ArtifactKind, BumpReason, ChangelogEntry, ModuleEvidence, PlannedModule, ReleaseDiagnostic, ReleaseEvidence, ReleasePlan, } from "./release-plan.js";
|
|
23
23
|
export { VersionStampError, readManifestVersion, stampCrateVersion, stampManifestVersion, stampSelfNpmPins, stampPackageVersion, } from "./version-stamp.js";
|
|
24
|
-
export {
|
|
25
|
-
export type {
|
|
24
|
+
export { checkDestinationCollisions, checkImportDestinations } from "./destinations.js";
|
|
25
|
+
export type { ImportDestination, ModuleDestination } from "./destinations.js";
|
|
26
|
+
export { DEFAULT_ENV_FILES, DEFAULT_RELEASE_IGNORE, WORKSPACE_FILENAME, WorkspaceConfigError, diagnosticsFor, hasError, matchesPatterns, readWorkspaceConfig, requireReleaseSettings, settingsForModule, } from "./workspace-config.js";
|
|
27
|
+
export type { EnvSettings, ModuleEntry, ModuleSettings, PatternMatch, ReleaseSettings, WorkspaceConfig, WorkspaceDiagnostic, WorkspaceDiagnosticCode, WorkspaceRead, } from "./workspace-config.js";
|
|
28
|
+
export { MODULE_ENTRY_KEYS, WORKSPACE_BLOCKS, WORKSPACE_SCHEMA, } from "./workspace-schema.js";
|
|
29
|
+
export type { WorkspaceBlockSchema, WorkspaceKeySchema } from "./workspace-schema.js";
|
|
26
30
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/release/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EACL,cAAc,EACd,mBAAmB,EACnB,SAAS,EACT,eAAe,EACf,cAAc,EACd,gBAAgB,EAChB,WAAW,EACX,QAAQ,GACT,MAAM,iBAAiB,CAAC;AACzB,YAAY,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/D,OAAO,EACL,gBAAgB,EAChB,uBAAuB,EACvB,sBAAsB,GACvB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AACpG,YAAY,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAEhE,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AACnG,YAAY,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAEvD,OAAO,EACL,sBAAsB,EACtB,cAAc,EACd,gBAAgB,EAChB,cAAc,GACf,MAAM,qBAAqB,CAAC;AAC7B,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAErE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChE,YAAY,EACV,YAAY,EACZ,UAAU,EACV,cAAc,EACd,cAAc,EACd,aAAa,EACb,iBAAiB,EACjB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EACf,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,iBAAiB,EACjB,oBAAoB,EACpB,gBAAgB,EAChB,mBAAmB,GACpB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,0BAA0B,EAAE,uBAAuB,EAAE,MAAM,mBAAmB,CAAC;AACxF,YAAY,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAE9E,OAAO,EACL,iBAAiB,EACjB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,EACd,QAAQ,EACR,eAAe,EACf,mBAAmB,EACnB,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAC/B,YAAY,EACV,WAAW,EACX,WAAW,EACX,cAAc,EACd,YAAY,EACZ,eAAe,EACf,eAAe,EACf,mBAAmB,EACnB,uBAAuB,EACvB,aAAa,GACd,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EACL,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,uBAAuB,CAAC;AAC/B,YAAY,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC"}
|
package/dist/release/index.js
CHANGED
|
@@ -15,4 +15,6 @@ export { EMPTY_LEDGER, LEDGER_PATH, LedgerError, parseLedger, serializeLedger }
|
|
|
15
15
|
export { LOCALLY_DERIVED_LAYERS, MANIFEST_LAYER, diffLayerDigests, layerDigestKey, } from "./payload-digest.js";
|
|
16
16
|
export { orderByImports, planRelease } from "./release-plan.js";
|
|
17
17
|
export { VersionStampError, readManifestVersion, stampCrateVersion, stampManifestVersion, stampSelfNpmPins, stampPackageVersion, } from "./version-stamp.js";
|
|
18
|
-
export {
|
|
18
|
+
export { checkDestinationCollisions, checkImportDestinations } from "./destinations.js";
|
|
19
|
+
export { DEFAULT_ENV_FILES, DEFAULT_RELEASE_IGNORE, WORKSPACE_FILENAME, WorkspaceConfigError, diagnosticsFor, hasError, matchesPatterns, readWorkspaceConfig, requireReleaseSettings, settingsForModule, } from "./workspace-config.js";
|
|
20
|
+
export { MODULE_ENTRY_KEYS, WORKSPACE_BLOCKS, WORKSPACE_SCHEMA, } from "./workspace-schema.js";
|
package/dist/release/ledger.d.ts
CHANGED
|
@@ -14,10 +14,22 @@
|
|
|
14
14
|
* drift: it means nothing is published, which is the correct reading for a
|
|
15
15
|
* module that has never shipped.
|
|
16
16
|
*
|
|
17
|
-
* **
|
|
18
|
-
* source writes the destination into the manifest layer — so
|
|
19
|
-
*
|
|
20
|
-
* another
|
|
17
|
+
* **Every entry records its own registry base**, because canonicalizing a
|
|
18
|
+
* relative `imports:` source writes the destination into the manifest layer — so
|
|
19
|
+
* each digest is a digest *against that base*, and comparing it to one taken
|
|
20
|
+
* against another would be comparing two different artifacts.
|
|
21
|
+
*
|
|
22
|
+
* Per entry rather than one top-level base with per-entry deltas: a workspace
|
|
23
|
+
* whose `release.modules` entries each author a destination has no meaningful
|
|
24
|
+
* top-level base, an absent one already means *nothing has been published yet*,
|
|
25
|
+
* and the agreement check returns early on that — so the multi-destination
|
|
26
|
+
* workspace would be the one whose bases are never compared. The file is
|
|
27
|
+
* generated and never hand-maintained, so the redundancy costs nothing and it
|
|
28
|
+
* removes the "differs from what?" question and the absent-versus-unknown
|
|
29
|
+
* conflation together. A **top-level `registry:` is a legacy form the reader
|
|
30
|
+
* accepts and never writes**, applied to every entry: the credential-free PR
|
|
31
|
+
* gate reads whatever ledger is committed on the branch, and that stays in the
|
|
32
|
+
* old shape until a release regenerates it.
|
|
21
33
|
*/
|
|
22
34
|
import { type ModuleKey } from "./fragment.js";
|
|
23
35
|
import type { LayerDigests } from "./payload-digest.js";
|
|
@@ -26,16 +38,13 @@ export interface LedgerEntry {
|
|
|
26
38
|
/** The version these digests were taken at — the tag the artifact published
|
|
27
39
|
* under. */
|
|
28
40
|
readonly version: string;
|
|
41
|
+
/** The publish destination base these digests were taken against
|
|
42
|
+
* (`oci://ghcr.io/telorun`). Absent only in a ledger written before the base
|
|
43
|
+
* was recorded at all. */
|
|
44
|
+
readonly registry?: string;
|
|
29
45
|
readonly layers: LayerDigests;
|
|
30
46
|
}
|
|
31
47
|
export interface Ledger {
|
|
32
|
-
/**
|
|
33
|
-
* The publish destination base the digests were taken against
|
|
34
|
-
* (`oci://ghcr.io/telorun`). Absent in a workspace that has published nothing
|
|
35
|
-
* yet, which is why it is optional rather than required — but a `check` that
|
|
36
|
-
* has entries and no base cannot reproduce them, and says so.
|
|
37
|
-
*/
|
|
38
|
-
readonly registry?: string;
|
|
39
48
|
readonly modules: ReadonlyMap<ModuleKey, LedgerEntry>;
|
|
40
49
|
}
|
|
41
50
|
export declare class LedgerError extends Error {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ledger.d.ts","sourceRoot":"","sources":["../../src/release/ledger.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"ledger.d.ts","sourceRoot":"","sources":["../../src/release/ledger.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAIH,OAAO,EAAsB,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAExD,eAAO,MAAM,WAAW,yBAAyB,CAAC;AAElD,MAAM,WAAW,WAAW;IAC1B;iBACa;IACb,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB;;+BAE2B;IAC3B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;CAC/B;AAED,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC,SAAS,EAAE,WAAW,CAAC,CAAC;CACvD;AAED,qBAAa,WAAY,SAAQ,KAAK;CAAG;AAEzC,eAAO,MAAM,YAAY,EAAE,MAA+B,CAAC;AAE3D,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAmF/D;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAmBtD"}
|
package/dist/release/ledger.js
CHANGED
|
@@ -14,10 +14,22 @@
|
|
|
14
14
|
* drift: it means nothing is published, which is the correct reading for a
|
|
15
15
|
* module that has never shipped.
|
|
16
16
|
*
|
|
17
|
-
* **
|
|
18
|
-
* source writes the destination into the manifest layer — so
|
|
19
|
-
*
|
|
20
|
-
* another
|
|
17
|
+
* **Every entry records its own registry base**, because canonicalizing a
|
|
18
|
+
* relative `imports:` source writes the destination into the manifest layer — so
|
|
19
|
+
* each digest is a digest *against that base*, and comparing it to one taken
|
|
20
|
+
* against another would be comparing two different artifacts.
|
|
21
|
+
*
|
|
22
|
+
* Per entry rather than one top-level base with per-entry deltas: a workspace
|
|
23
|
+
* whose `release.modules` entries each author a destination has no meaningful
|
|
24
|
+
* top-level base, an absent one already means *nothing has been published yet*,
|
|
25
|
+
* and the agreement check returns early on that — so the multi-destination
|
|
26
|
+
* workspace would be the one whose bases are never compared. The file is
|
|
27
|
+
* generated and never hand-maintained, so the redundancy costs nothing and it
|
|
28
|
+
* removes the "differs from what?" question and the absent-versus-unknown
|
|
29
|
+
* conflation together. A **top-level `registry:` is a legacy form the reader
|
|
30
|
+
* accepts and never writes**, applied to every entry: the credential-free PR
|
|
31
|
+
* gate reads whatever ledger is committed on the branch, and that stays in the
|
|
32
|
+
* old shape until a release regenerates it.
|
|
21
33
|
*/
|
|
22
34
|
import { Document, parseDocument } from "yaml";
|
|
23
35
|
import { isReleaseVersion } from "./bump-level.js";
|
|
@@ -45,13 +57,14 @@ export function parseLedger(text, where) {
|
|
|
45
57
|
throw new LedgerError(`${where}: unknown field '${key}'. The ledger carries 'registry:' and 'modules:'.`);
|
|
46
58
|
}
|
|
47
59
|
}
|
|
48
|
-
|
|
49
|
-
|
|
60
|
+
// The legacy top-level base: read and applied to every entry, never written.
|
|
61
|
+
const inherited = record.registry;
|
|
62
|
+
if (inherited !== undefined && typeof inherited !== "string") {
|
|
50
63
|
throw new LedgerError(`${where}: 'registry' must be the publish destination base, as a string.`);
|
|
51
64
|
}
|
|
52
65
|
const rawModules = record.modules;
|
|
53
66
|
if (rawModules === undefined || rawModules === null)
|
|
54
|
-
return {
|
|
67
|
+
return { modules: new Map() };
|
|
55
68
|
if (typeof rawModules !== "object" || Array.isArray(rawModules)) {
|
|
56
69
|
throw new LedgerError(`${where}: 'modules' must be a mapping of module path to entry.`);
|
|
57
70
|
}
|
|
@@ -61,6 +74,16 @@ export function parseLedger(text, where) {
|
|
|
61
74
|
throw new LedgerError(`${where}: entry '${key}' must be a mapping.`);
|
|
62
75
|
}
|
|
63
76
|
const entry = raw;
|
|
77
|
+
for (const field of Object.keys(entry)) {
|
|
78
|
+
if (field !== "version" && field !== "registry" && field !== "layers") {
|
|
79
|
+
throw new LedgerError(`${where}: entry '${key}' has unknown field '${field}'. An entry carries 'version:', ` +
|
|
80
|
+
`'registry:' and 'layers:'.`);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
if (entry.registry !== undefined && typeof entry.registry !== "string") {
|
|
84
|
+
throw new LedgerError(`${where}: entry '${key}' has a non-string 'registry'. It is the publish destination base ` +
|
|
85
|
+
`the digests beside it were taken against.`);
|
|
86
|
+
}
|
|
64
87
|
if (!isReleaseVersion(entry.version)) {
|
|
65
88
|
throw new LedgerError(`${where}: entry '${key}' has no major.minor.patch 'version'. The ledger records the ` +
|
|
66
89
|
`version each digest was taken at; without it the digest says nothing.`);
|
|
@@ -78,9 +101,14 @@ export function parseLedger(text, where) {
|
|
|
78
101
|
layers[layer] = digest;
|
|
79
102
|
}
|
|
80
103
|
}
|
|
81
|
-
|
|
104
|
+
const registry = entry.registry ?? inherited;
|
|
105
|
+
modules.set(normalizeModuleKey(key), {
|
|
106
|
+
version: entry.version,
|
|
107
|
+
...(registry ? { registry } : {}),
|
|
108
|
+
layers,
|
|
109
|
+
});
|
|
82
110
|
}
|
|
83
|
-
return {
|
|
111
|
+
return { modules };
|
|
84
112
|
}
|
|
85
113
|
/**
|
|
86
114
|
* Render the ledger.
|
|
@@ -96,12 +124,13 @@ export function serializeLedger(ledger) {
|
|
|
96
124
|
const layers = {};
|
|
97
125
|
for (const layer of Object.keys(entry.layers).sort())
|
|
98
126
|
layers[layer] = entry.layers[layer];
|
|
99
|
-
modules[key] = {
|
|
127
|
+
modules[key] = {
|
|
128
|
+
version: entry.version,
|
|
129
|
+
...(entry.registry ? { registry: entry.registry } : {}),
|
|
130
|
+
layers,
|
|
131
|
+
};
|
|
100
132
|
}
|
|
101
|
-
const doc = new Document({
|
|
102
|
-
...(ledger.registry ? { registry: ledger.registry } : {}),
|
|
103
|
-
modules,
|
|
104
|
-
});
|
|
133
|
+
const doc = new Document({ modules });
|
|
105
134
|
return ("# Generated by `telo release apply` — what each module looks like as published.\n" +
|
|
106
135
|
"# A cache of the registry's answer, so a PR gate needs no credentials.\n" +
|
|
107
136
|
"# `telo release verify` reconciles it against the registry.\n" +
|
|
@@ -58,13 +58,14 @@ export interface ModuleEvidence {
|
|
|
58
58
|
/** Whether a file under this module's own directory that reaches the artifact
|
|
59
59
|
* changed. Decides only whether a changelog line is requested. */
|
|
60
60
|
readonly ownFilesChanged: boolean;
|
|
61
|
+
/** The publish destination base THIS module's payload was built against —
|
|
62
|
+
* per module, because a workspace may declare one per subtree. */
|
|
63
|
+
readonly registry: string;
|
|
61
64
|
}
|
|
62
65
|
export interface ReleaseEvidence {
|
|
63
66
|
readonly modules: readonly ModuleEvidence[];
|
|
64
67
|
readonly ledger: Ledger;
|
|
65
68
|
readonly fragments: readonly ReleaseFragment[];
|
|
66
|
-
/** The publish destination base the digests above were built against. */
|
|
67
|
-
readonly registry?: string;
|
|
68
69
|
}
|
|
69
70
|
/** Why a module is in the plan. A module usually carries several. */
|
|
70
71
|
export type BumpReason = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"release-plan.d.ts","sourceRoot":"","sources":["../../src/release/release-plan.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAGL,KAAK,SAAS,EACd,KAAK,YAAY,EAElB,MAAM,iBAAiB,CAAC;AACzB,OAAO,KAAK,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAoB,KAAK,WAAW,EAAE,KAAK,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAE5F;;uDAEuD;AACvD,MAAM,MAAM,YAAY,GAAG,UAAU,GAAG,OAAO,CAAC;AAEhD,MAAM,WAAW,cAAc;IAC7B,uEAAuE;IACvE,QAAQ,CAAC,GAAG,EAAE,SAAS,CAAC;IACxB,yCAAyC;IACzC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,2DAA2D;IAC3D,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC;IACpC,sEAAsE;IACtE,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAC9B;;;;;;OAMG;IACH,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC,CAAC;IAC5D;;;;OAIG;IACH,QAAQ,CAAC,OAAO,EAAE,SAAS,SAAS,EAAE,CAAC;IACvC;uEACmE;IACnE,QAAQ,CAAC,eAAe,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"release-plan.d.ts","sourceRoot":"","sources":["../../src/release/release-plan.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAGL,KAAK,SAAS,EACd,KAAK,YAAY,EAElB,MAAM,iBAAiB,CA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C,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC,QAAQ,CAAC,WAAW,EAAE,SAAS,iBAAiB,EAAE,CAAC;CACpD;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,eAAe,GAAG,WAAW,CAwHlE;AAgHD;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,SAAS,cAAc,EAAE,GAAG,cAAc,EAAE,CAgBnF"}
|
|
@@ -28,7 +28,6 @@ import { diffLayerDigests } from "./payload-digest.js";
|
|
|
28
28
|
export function planRelease(evidence) {
|
|
29
29
|
const diagnostics = [];
|
|
30
30
|
const byKey = new Map(evidence.modules.map((module) => [module.key, module]));
|
|
31
|
-
checkRegistryAgreement(evidence, diagnostics);
|
|
32
31
|
// What the digest says, per module. A module with no ledger entry has never
|
|
33
32
|
// been published, which is not drift — there is nothing to differ from.
|
|
34
33
|
const drift = new Map();
|
|
@@ -36,6 +35,18 @@ export function planRelease(evidence) {
|
|
|
36
35
|
const recorded = evidence.ledger.modules.get(module.key);
|
|
37
36
|
if (!recorded)
|
|
38
37
|
continue;
|
|
38
|
+
if (recorded.registry && recorded.registry !== module.registry) {
|
|
39
|
+
diagnostics.push({
|
|
40
|
+
severity: "error",
|
|
41
|
+
code: "LEDGER_REGISTRY_MISMATCH",
|
|
42
|
+
message: `${module.key}: its ledger digests were taken against '${recorded.registry}', but this ` +
|
|
43
|
+
`run built against '${module.registry}'. Publishing rewrites each relative import to ` +
|
|
44
|
+
`'<base>/<sibling>@<version>', so the manifest layers of the two are different bytes ` +
|
|
45
|
+
`and comparing them would report the module as changed. Publish to the recorded base, ` +
|
|
46
|
+
`or re-record with \`telo release verify --write\`.`,
|
|
47
|
+
});
|
|
48
|
+
continue;
|
|
49
|
+
}
|
|
39
50
|
if (recorded.version !== module.version) {
|
|
40
51
|
diagnostics.push({
|
|
41
52
|
severity: "error",
|
|
@@ -228,24 +239,6 @@ function requestMissingChangelogEntries(modules, entries, diagnostics) {
|
|
|
228
239
|
`One \`telo release add\` can name them all.`,
|
|
229
240
|
});
|
|
230
241
|
}
|
|
231
|
-
/**
|
|
232
|
-
* The base the digests were built against has to be the base they were recorded
|
|
233
|
-
* against, or the manifest layers are not comparable: canonicalization writes
|
|
234
|
-
* the destination into them.
|
|
235
|
-
*/
|
|
236
|
-
function checkRegistryAgreement(evidence, diagnostics) {
|
|
237
|
-
const recorded = evidence.ledger.registry;
|
|
238
|
-
if (!recorded || !evidence.registry || recorded === evidence.registry)
|
|
239
|
-
return;
|
|
240
|
-
diagnostics.push({
|
|
241
|
-
severity: "error",
|
|
242
|
-
code: "LEDGER_REGISTRY_MISMATCH",
|
|
243
|
-
message: `The ledger's digests were taken against '${recorded}', but this run built against ` +
|
|
244
|
-
`'${evidence.registry}'. Publishing rewrites each relative import to ` +
|
|
245
|
-
`'<base>/<sibling>@<version>', so the manifest layers of the two are different bytes ` +
|
|
246
|
-
`and comparing them would report every module as changed.`,
|
|
247
|
-
});
|
|
248
|
-
}
|
|
249
242
|
/**
|
|
250
243
|
* Dependency order over in-repo imports — a dependency before its dependents.
|
|
251
244
|
*
|