@telorun/kernel 0.55.0 → 0.57.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.
Files changed (39) hide show
  1. package/dist/bundle/module-manifest.d.ts +2 -3
  2. package/dist/bundle/module-manifest.d.ts.map +1 -1
  3. package/dist/bundle/module-manifest.js +2 -3
  4. package/dist/bundle/module-manifest.js.map +1 -1
  5. package/dist/kernel.d.ts.map +1 -1
  6. package/dist/kernel.js +5 -3
  7. package/dist/kernel.js.map +1 -1
  8. package/dist/manifest-schemas.js +1 -1
  9. package/dist/manifest-sources/local-manifest-cache-source.d.ts.map +1 -1
  10. package/dist/manifest-sources/local-manifest-cache-source.js +10 -6
  11. package/dist/manifest-sources/local-manifest-cache-source.js.map +1 -1
  12. package/dist/transports/oci/oci-ref.d.ts +1 -1
  13. package/dist/transports/oci/oci-ref.d.ts.map +1 -1
  14. package/dist/transports/oci/oci-ref.js +1 -1
  15. package/dist/transports/oci/oci-ref.js.map +1 -1
  16. package/dist/transports/oci/oci-transport.d.ts +8 -4
  17. package/dist/transports/oci/oci-transport.d.ts.map +1 -1
  18. package/dist/transports/oci/oci-transport.js +20 -14
  19. package/dist/transports/oci/oci-transport.js.map +1 -1
  20. package/dist/transports/registry-transport.d.ts +6 -4
  21. package/dist/transports/registry-transport.d.ts.map +1 -1
  22. package/dist/transports/registry-transport.js +84 -26
  23. package/dist/transports/registry-transport.js.map +1 -1
  24. package/dist/transports/transport-registry.d.ts +4 -4
  25. package/dist/transports/transport-registry.d.ts.map +1 -1
  26. package/dist/transports/transport-registry.js +4 -4
  27. package/dist/transports/transport-registry.js.map +1 -1
  28. package/dist/transports/transport.d.ts +27 -19
  29. package/dist/transports/transport.d.ts.map +1 -1
  30. package/package.json +3 -3
  31. package/src/bundle/module-manifest.ts +2 -4
  32. package/src/kernel.ts +5 -3
  33. package/src/manifest-schemas.ts +1 -1
  34. package/src/manifest-sources/local-manifest-cache-source.ts +15 -6
  35. package/src/transports/oci/oci-ref.ts +8 -1
  36. package/src/transports/oci/oci-transport.ts +26 -14
  37. package/src/transports/registry-transport.ts +84 -25
  38. package/src/transports/transport-registry.ts +5 -5
  39. package/src/transports/transport.ts +27 -20
@@ -1,4 +1,4 @@
1
- import { DEFAULT_MANIFEST_FILENAME, HttpSource, IntegrityError, RegistrySource, isRegistryRef, parseModuleRef, sha256Base64Url, splitIntegrity, } from "@telorun/analyzer";
1
+ import { DEFAULT_MANIFEST_FILENAME, HttpSource, IntegrityError, RegistrySource, isRegistryRef, parseModuleRef, parseVersionedRef, sha256Base64Url, withRefVersion, splitIntegrity, } from "@telorun/analyzer";
2
2
  import { fetchOrThrow } from "@telorun/sdk";
3
3
  import { createHash } from "crypto";
4
4
  import { computeFilesIntegrity } from "../bundle/files-integrity.js";
@@ -6,7 +6,20 @@ import { readOwnerManifest } from "../bundle/module-manifest.js";
6
6
  import { readTarGz, toPayloadFiles } from "../bundle/tar.js";
7
7
  import { assertPublicEgress } from "./egress-guard.js";
8
8
  const DEFAULT_REGISTRY_URL = "https://registry.telo.run";
9
- const HTTP_NAMESPACE = "__http";
9
+ /** Throwaway origin that lets a bare registry ref use URL path resolution. */
10
+ const JOIN_ORIGIN = "https://ref.invalid";
11
+ /** True for an HTTP(S) destination that names a registry root rather than a
12
+ * module within it — no path segments to resolve a sibling beside. */
13
+ function isRegistryBase(base) {
14
+ if (!base.startsWith("http://") && !base.startsWith("https://"))
15
+ return false;
16
+ try {
17
+ return new URL(base).pathname.replace(/\/+/g, "/").replace(/^\/|\/$/g, "") === "";
18
+ }
19
+ catch {
20
+ return false;
21
+ }
22
+ }
10
23
  const QUERY_HASH_LENGTH = 12;
11
24
  /** Mirror `HttpSource.read`'s `fetchUrl` derivation: when the URL does not
12
25
  * already point at a YAML file, append `/telo.yaml`, so a raw import URL and
@@ -63,11 +76,16 @@ export class RegistryTransport {
63
76
  const { base } = splitIntegrity(ref);
64
77
  return base.startsWith("http://") || base.startsWith("https://") || isRegistryRef(ref);
65
78
  }
66
- cacheLocation(ref) {
79
+ cacheCoords(ref) {
67
80
  const url = splitIntegrity(ref).base;
68
81
  const trimmedRegistry = this.registryUrl.replace(/\/+$/, "");
69
- // 1. Registry ref form: namespace/name@version
82
+ const registryHost = this.registryHost();
83
+ // 1. Registry ref form: <path>@<version>. Keyed under the registry's host —
84
+ // a ref says nothing about which registry serves it, so without the host
85
+ // two registries' copies of the same path/version share one cache entry.
70
86
  if (isRegistryRef(url)) {
87
+ if (!registryHost)
88
+ return null;
71
89
  let parsed;
72
90
  try {
73
91
  parsed = parseModuleRef(url);
@@ -75,7 +93,12 @@ export class RegistryTransport {
75
93
  catch {
76
94
  return null;
77
95
  }
78
- return [parsed.modulePath, parsed.version, DEFAULT_MANIFEST_FILENAME];
96
+ return {
97
+ transport: "registry",
98
+ host: registryHost,
99
+ path: parsed.modulePath,
100
+ version: parsed.version,
101
+ };
79
102
  }
80
103
  // 2. HTTP(S) URL — a direct registry URL or arbitrary external.
81
104
  if (url.startsWith("http://") || url.startsWith("https://")) {
@@ -90,21 +113,46 @@ export class RegistryTransport {
90
113
  // 2a. On the configured registry, no query/fragment: fold into the
91
114
  // registry layout so a ref and a direct URL land on the same file.
92
115
  const normalizedUrl = `${parsed.protocol}//${parsed.host}${pathname}`;
93
- if (!parsed.search &&
116
+ if (registryHost &&
117
+ !parsed.search &&
94
118
  !parsed.hash &&
95
- (normalizedUrl === trimmedRegistry || normalizedUrl.startsWith(`${trimmedRegistry}/`))) {
96
- const rel = normalizedUrl.slice(trimmedRegistry.length + 1);
97
- if (!rel)
98
- return null;
99
- return rel.split("/");
119
+ normalizedUrl.startsWith(`${trimmedRegistry}/`)) {
120
+ // The registry serves `<path…>/<version>/<file>`, where `<file>` is the
121
+ // module manifest or one of its `include:` partials.
122
+ const segments = normalizedUrl.slice(trimmedRegistry.length + 1).split("/");
123
+ const file = segments.pop();
124
+ const version = segments.pop();
125
+ if (file && version && segments.length > 0) {
126
+ return {
127
+ transport: "registry",
128
+ host: registryHost,
129
+ path: segments.join("/"),
130
+ version,
131
+ file,
132
+ };
133
+ }
100
134
  }
101
- // 2b. Arbitrary HTTP(S) → __http subtree, query-hash suffix on collision.
135
+ // 2b. Arbitrary HTTP(S) → `url` subtree, query-hash suffix on collision.
136
+ // No version segment: a URL addresses exactly one file, and the
137
+ // version it declares lives inside bytes the cache maps paths without.
102
138
  const cleanPath = pathname.startsWith("/") ? pathname.slice(1) : pathname;
103
- const disambiguated = disambiguatePath(cleanPath, parsed.search, parsed.hash);
104
- return [HTTP_NAMESPACE, parsed.host, ...disambiguated.split("/")];
139
+ const segments = disambiguatePath(cleanPath, parsed.search, parsed.hash).split("/");
140
+ const file = segments.pop();
141
+ if (!file)
142
+ return null;
143
+ return { transport: "url", host: parsed.host, path: segments.join("/"), file };
105
144
  }
106
145
  return null;
107
146
  }
147
+ /** Host of the configured registry, or `null` when the URL is unparseable. */
148
+ registryHost() {
149
+ try {
150
+ return new URL(this.registryUrl).host || null;
151
+ }
152
+ catch {
153
+ return null;
154
+ }
155
+ }
108
156
  async listVersions(ref) {
109
157
  // Only bare registry refs are version-enumerable — a direct `https://` URL
110
158
  // has no version-list endpoint.
@@ -125,15 +173,10 @@ export class RegistryTransport {
125
173
  refVersion(ref) {
126
174
  // Only bare `namespace/name@version` refs carry an upgradeable version — a
127
175
  // direct `https://` URL has no version segment to bump.
128
- if (!isRegistryRef(ref))
129
- return null;
130
- const { base } = splitIntegrity(ref);
131
- const at = base.lastIndexOf("@");
132
- return at > 0 ? base.slice(at + 1) : null;
176
+ return isRegistryRef(ref) ? (parseVersionedRef(ref)?.version ?? null) : null;
133
177
  }
134
178
  withVersion(ref, version) {
135
- const { modulePath } = parseModuleRef(ref);
136
- return `${modulePath}@${version}`;
179
+ return withRefVersion(ref, version);
137
180
  }
138
181
  /** Mirrors the sources' fetch-URL derivation: a direct URL points at (or
139
182
  * contains) the YAML file; a bare registry ref folds into the registry
@@ -224,12 +267,27 @@ export class RegistryTransport {
224
267
  throw new Error("Publishing to the HTTP Telo registry has been removed. Publish to an OCI " +
225
268
  "registry (oci://host/repo) instead.");
226
269
  }
227
- canonicalizeSiblingRef(_destination, _relativeSource, sibling) {
228
- // An HTTP registry path defaults to the sibling's own `<namespace>/<name>`.
229
- if (!sibling.namespace || !sibling.name) {
230
- throw new Error("a relative import canonicalized to an HTTP registry needs the sibling's metadata.namespace and metadata.name.");
270
+ canonicalizeSiblingRef(destination, relativeSource, version) {
271
+ // The sibling sits beside the destination module: resolve the relative path
272
+ // against the destination's own path, then pin the sibling's version. A bare
273
+ // registry ref (`std/foo`) is a path, not a URL, so it borrows a throwaway
274
+ // origin for the join and drops it again.
275
+ const base = splitIntegrity(destination).base.replace(/@[^/@]*$/, "");
276
+ // A registry *base* (`https://registry.telo.run`) is not a module location,
277
+ // so there is nothing for `../lib` to resolve beside — joining anyway would
278
+ // silently produce a ref one path segment short.
279
+ if (isRegistryBase(base)) {
280
+ throw new Error(`cannot canonicalize the relative import '${relativeSource}': publish destination ` +
281
+ `'${destination}' is a registry base, not this module's own location. Pass the ` +
282
+ `module's full destination (e.g. '${base.replace(/\/+$/, "")}/<namespace>/<name>').`);
231
283
  }
232
- return `${sibling.namespace}/${sibling.name}@${sibling.version}`;
284
+ const isUrl = base.startsWith("http://") || base.startsWith("https://");
285
+ const origin = isUrl ? base : `${JOIN_ORIGIN}/${base.replace(/^\/+/, "")}`;
286
+ const resolved = new URL(relativeSource, `${origin.replace(/\/+$/, "")}/`);
287
+ const joined = isUrl
288
+ ? `${resolved.protocol}//${resolved.host}${resolved.pathname}`
289
+ : resolved.pathname.replace(/^\/+/, "");
290
+ return `${joined.replace(/\/+$/, "")}@${version}`;
233
291
  }
234
292
  }
235
293
  //# sourceMappingURL=registry-transport.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"registry-transport.js","sourceRoot":"","sources":["../../src/transports/registry-transport.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,yBAAyB,EACzB,UAAU,EACV,cAAc,EACd,cA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MAAM,IAAI,KAAK,CACb,2EAA2E;YACzE,qCAAqC,CACxC,CAAC;IACJ,CAAC;IAED,sBAAsB,CACpB,YAAoB,EACpB,eAAuB,EACvB,OAAwB;QAExB,4EAA4E;QAC5E,IAAI,CAAC,OAAO,CAAC,SAAS,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC;YACxC,MAAM,IAAI,KAAK,CACb,+GAA+G,CAChH,CAAC;QACJ,CAAC;QACD,OAAO,GAAG,OAAO,CAAC,SAAS,IAAI,OAAO,CAAC,IAAI,IAAI,OAAO,CAAC,OAAO,EAAE,CAAC;IACnE,CAAC;CACF"}
1
+ {"version":3,"file":"registry-transport.js","sourceRoot":"","sources":["../../src/transports/registry-transport.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,yBAAyB,EACzB,UAAU,EACV,cAAc,EACd,cAAc,EACd,aAAa,EACb,cAAc,EACd,iBAAiB,EACjB,eAAe,EACf,cAAc,EACd,cAAc,GAGf,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AAEpC,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AASvD,MAAM,oBAAoB,GAAG,2BAA2B,CAAC;AACzD,8EAA8E;AAC9E,MAAM,WAAW,GAAG,qBAAqB,CAAC;AAE1C;uEACuE;AACvE,SAAS,cAAc,CAAC,IAAY;IAClC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC;QAAE,OAAO,KAAK,CAAC;IAC9E,IAAI,CAAC;Q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E,CAAC;QAC3E,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,cAAc,EAAE,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC;QAC3E,MAAM,MAAM,GAAG,KAAK;YAClB,CAAC,CAAC,GAAG,QAAQ,CAAC,QAAQ,KAAK,QAAQ,CAAC,IAAI,GAAG,QAAQ,CAAC,QAAQ,EAAE;YAC9D,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;QAC1C,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,IAAI,OAAO,EAAE,CAAC;IACpD,CAAC;CACF"}
@@ -1,4 +1,4 @@
1
- import type { ManifestSource } from "@telorun/analyzer";
1
+ import type { ManifestCacheCoords, ManifestSource } from "@telorun/analyzer";
2
2
  import type { FetchedArtifact, PublishBundle, PublishOptions, PublishResult, Transport } from "./transport.js";
3
3
  /** Dispatches ref-scheme-specific operations to the transport that owns a ref.
4
4
  * The loader, cache source, `upgrade`, and `publish` consult this instead of
@@ -13,9 +13,9 @@ export declare class TransportRegistry {
13
13
  /** The resolution `ManifestSource`s of every registered transport, in order —
14
14
  * the browser-safe subset the loader appends to its source chain. */
15
15
  sources(): ManifestSource[];
16
- /** Cache-path segments for `ref`, from its owning transport; `null` when no
17
- * transport owns it or the ref is not cacheable. */
18
- cacheLocation(ref: string): string[] | null;
16
+ /** Manifest-cache coordinates for `ref`, from its owning transport; `null`
17
+ * when no transport owns it or the ref is not cacheable. */
18
+ cacheCoords(ref: string): ManifestCacheCoords | null;
19
19
  /** Published versions for `ref` via its owning transport; `null` when the
20
20
  * module is unpublished. Throws when no transport owns the ref. */
21
21
  listVersions(ref: string): Promise<string[] | null>;
@@ -1 +1 @@
1
- {"version":3,"file":"transport-registry.d.ts","sourceRoot":"","sources":["../../src/transports/transport-registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAIxD,OAAO,KAAK,EACV,eAAe,EACf,aAAa,EACb,cAAc,EACd,aAAa,EACb,SAAS,EACV,MAAM,gBAAgB,CAAC;AAExB;;;;2EAI2E;AAC3E,qBAAa,iBAAiB;IAChB,OAAO,CAAC,QAAQ,CAAC,UAAU;gBAAV,UAAU,EAAE,SAAS,EAAE;IAEpD,kEAAkE;IAClE,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS;IAI1C;0EACsE;IACtE,OAAO,IAAI,cAAc,EAAE;IAI3B;yDACqD;IACrD,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,IAAI;IAI3C;wEACoE;IACpE,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC;IAInD;wBACoB;IACpB,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC;IAIpD;kFAC8E;IAC9E,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IAI3C;yDACqD;IACrD,OAAO,CACL,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,aAAa,EACrB,IAAI,CAAC,EAAE,cAAc,GACpB,OAAO,CAAC,aAAa,CAAC;IAIzB,OAAO,CAAC,OAAO;CAOhB;AAED;;oFAEoF;AACpF,wBAAgB,iBAAiB,CAAC,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,CAEnE;AAID;;;;2DAI2D;AAC3D,wBAAgB,wBAAwB,CAAC,WAAW,CAAC,EAAE,MAAM,GAAG,iBAAiB,CAQhF"}
1
+ {"version":3,"file":"transport-registry.d.ts","sourceRoot":"","sources":["../../src/transports/transport-registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAI7E,OAAO,KAAK,EACV,eAAe,EACf,aAAa,EACb,cAAc,EACd,aAAa,EACb,SAAS,EACV,MAAM,gBAAgB,CAAC;AAExB;;;;2EAI2E;AAC3E,qBAAa,iBAAiB;IAChB,OAAO,CAAC,QAAQ,CAAC,UAAU;gBAAV,UAAU,EAAE,SAAS,EAAE;IAEpD,kEAAkE;IAClE,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS;IAI1C;0EACsE;IACtE,OAAO,IAAI,cAAc,EAAE;IAI3B;iEAC6D;IAC7D,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,mBAAmB,GAAG,IAAI;IAIpD;wEACoE;IACpE,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC;IAInD;wBACoB;IACpB,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC;IAIpD;kFAC8E;IAC9E,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IAI3C;yDACqD;IACrD,OAAO,CACL,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,aAAa,EACrB,IAAI,CAAC,EAAE,cAAc,GACpB,OAAO,CAAC,aAAa,CAAC;IAIzB,OAAO,CAAC,OAAO;CAOhB;AAED;;oFAEoF;AACpF,wBAAgB,iBAAiB,CAAC,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,CAEnE;AAID;;;;2DAI2D;AAC3D,wBAAgB,wBAAwB,CAAC,WAAW,CAAC,EAAE,MAAM,GAAG,iBAAiB,CAQhF"}
@@ -18,10 +18,10 @@ export class TransportRegistry {
18
18
  sources() {
19
19
  return this.transports.map((t) => t.source);
20
20
  }
21
- /** Cache-path segments for `ref`, from its owning transport; `null` when no
22
- * transport owns it or the ref is not cacheable. */
23
- cacheLocation(ref) {
24
- return this.forRef(ref)?.cacheLocation(ref) ?? null;
21
+ /** Manifest-cache coordinates for `ref`, from its owning transport; `null`
22
+ * when no transport owns it or the ref is not cacheable. */
23
+ cacheCoords(ref) {
24
+ return this.forRef(ref)?.cacheCoords(ref) ?? null;
25
25
  }
26
26
  /** Published versions for `ref` via its owning transport; `null` when the
27
27
  * module is unpublished. Throws when no transport owns the ref. */
@@ -1 +1 @@
1
- {"version":3,"file":"transport-registry.js","sourceRoot":"","sources":["../../src/transports/transport-registry.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAS5D;;;;2EAI2E;AAC3E,MAAM,OAAO,iBAAiB;IAC5B,YAA6B,UAAuB;QAAvB,eAAU,GAAV,UAAU,CAAa;IAAG,CAAC;IAExD,kEAAkE;IAClE,MAAM,CAAC,GAAW;QAChB,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC;IACtD,CAAC;IAED;0EACsE;IACtE,OAAO;QACL,OAAO,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;IAC9C,CAAC;IAED;yDACqD;IACrD,aAAa,CAAC,GAAW;QACvB,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,aAAa,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC;IACtD,CAAC;IAED;wEACoE;IACpE,YAAY,CAAC,GAAW;QACtB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC;IAC7C,CAAC;IAED;wBACoB;IACpB,aAAa,CAAC,GAAW;QACvB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,aAAa,CAAC,GAAG,CAAC,CAA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O,CAAC,WAAW,EAAE,MAAM,EAAE,IAAI,CAAC,CAAC;IACtE,CAAC;IAEO,OAAO,CAAC,GAAW;QACzB,MAAM,SAAS,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;QACnC,IAAI,CAAC,SAAS,EAAE,CAAC;YACf,MAAM,IAAI,KAAK,CAAC,0BAA0B,GAAG,GAAG,CAAC,CAAC;QACpD,CAAC;QACD,OAAO,SAAS,CAAC;IACnB,CAAC;CACF;AAED;;oFAEoF;AACpF,MAAM,UAAU,iBAAiB,CAAC,WAAoB;IACpD,OAAO,CAAC,IAAI,YAAY,EAAE,EAAE,IAAI,iBAAiB,CAAC,WAAW,CAAC,CAAC,CAAC;AAClE,CAAC;AAED,MAAM,oBAAoB,GAAG,IAAI,GAAG,EAA6B,CAAC;AAElE;;;;2DAI2D;AAC3D,MAAM,UAAU,wBAAwB,CAAC,WAAoB;IAC3D,MAAM,GAAG,GAAG,WAAW,IAAI,EAAE,CAAC;IAC9B,IAAI,MAAM,GAAG,oBAAoB,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC3C,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,MAAM,GAAG,IAAI,iBAAiB,CAAC,iBAAiB,CAAC,WAAW,CAAC,CAAC,CAAC;QAC/D,oBAAoB,CAAC,GAAG,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;IACxC,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { ManifestSource } from "@telorun/analyzer";
1
+ import type { ManifestCacheCoords, ManifestSource } from "@telorun/analyzer";
2
2
  import type { PayloadFile } from "../bundle/files-integrity.js";
3
3
  /** The full module artifact a transport delivers: the `telo.yaml` bytes plus
4
4
  * the decompressed `files:` payload (empty for a manifest-only module). The
@@ -23,14 +23,6 @@ export interface PublishResult {
23
23
  /** The location the artifact was written to. */
24
24
  url: string;
25
25
  }
26
- /** Identity of a sibling library, read from its own manifest, that a relative
27
- * import canonicalizes to. `version` is always required; `namespace`/`name` are
28
- * used only by transports whose location is metadata-derived (HTTP registry). */
29
- export interface SiblingIdentity {
30
- namespace?: string;
31
- name?: string;
32
- version: string;
33
- }
34
26
  export interface PublishOptions {
35
27
  /** Bearer token for registries that require auth. */
36
28
  token?: string;
@@ -54,7 +46,7 @@ export interface PublishOptions {
54
46
  * `ManifestSource` is the browser-safe resolution primitive (also implemented
55
47
  * by the cache / local / memory sources, which have no versions and nothing to
56
48
  * publish), so it stays in `analyzer`, while the Node-only management methods
57
- * (`cacheLocation` and, in later phases, `listVersions` / `fetchArtifact` /
49
+ * (`cacheCoords` and, in later phases, `listVersions` / `fetchArtifact` /
58
50
  * `publish`) live on the Transport here in `kernel`. */
59
51
  export interface Transport {
60
52
  /** True when this transport owns the given ref (or publish destination). */
@@ -63,10 +55,21 @@ export interface Transport {
63
55
  * Browser-safe for a browser-reachable transport (HTTP/registry), so it can
64
56
  * live in `analyzer`; a Node-only transport has no browser-safe source. */
65
57
  readonly source: ManifestSource;
66
- /** Deterministic cache-path segments for a ref, joined under the cache root by
67
- * the cache source. Returns `null` when the ref is not cacheable here
68
- * (unsupported scheme, malformed ref, or path-traversal in the ref). */
69
- cacheLocation(ref: string): string[] | null;
58
+ /** Where a ref's `telo.yaml` is cached, as the transport-neutral
59
+ * `{ transport, host, path, version, file }` coordinates the analyzer's
60
+ * `manifestCacheKey` renders into a path. One grammar serves the local
61
+ * install cache, the hub's static manifest bucket, and the editor's read
62
+ * path, so the three cannot drift on the *shape* of a cache key.
63
+ *
64
+ * They do differ on coordinates, deliberately, for a `url` ref: the hub reads
65
+ * the version out of the fetched manifest and keys by it, while this cache
66
+ * maps a ref to a path before any fetch and so has no version to supply —
67
+ * it names the file instead, since it also stores each `include:` partial.
68
+ * Same grammar, different coordinates; not a drift to reconcile.
69
+ *
70
+ * Returns `null` when the ref is not cacheable here (unsupported scheme,
71
+ * malformed ref, or path-traversal in the ref). */
72
+ cacheCoords(ref: string): ManifestCacheCoords | null;
70
73
  /** The versions published for the module `ref` names, newest-first order not
71
74
  * guaranteed (the caller sorts). Returns `null` when the module is not
72
75
  * published (e.g. a 404), distinct from `[]` (published, no versions). Used
@@ -126,10 +129,15 @@ export interface Transport {
126
129
  publish(destination: string, bundle: PublishBundle, opts?: PublishOptions): Promise<PublishResult>;
127
130
  /** Canonicalize a relative sibling import (`../lib`) declared in a module
128
131
  * being published to `destination` into the absolute ref it will resolve to
129
- * once published. Owns the scheme-specific "where does a sibling land" rule —
130
- * OCI derives the repo from the destination, HTTP from the sibling's
131
- * `<namespace>/<name>` so `telo publish` delegates instead of branching on
132
- * transport shape. */
133
- canonicalizeSiblingRef(destination: string, relativeSource: string, sibling: SiblingIdentity): string;
132
+ * once published.
133
+ *
134
+ * The sibling lands beside the destination: the destination's last segment is
135
+ * the module's own directory, so the relative path resolves against it
136
+ * exactly as it does on the publisher's disk — publishing `…/telorun/foo`
137
+ * with an import of `../bar` yields `…/telorun/bar`. Only the version comes
138
+ * from the sibling's own manifest; nothing is read from its metadata to
139
+ * decide where it lives. Each transport owns the join for its ref grammar, so
140
+ * `telo publish` delegates instead of branching on transport shape. */
141
+ canonicalizeSiblingRef(destination: string, relativeSource: string, version: string): string;
134
142
  }
135
143
  //# sourceMappingURL=transport.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"transport.d.ts","sourceRoot":"","sources":["../../src/transports/transport.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAEhE;;;sDAGsD;AACtD,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,WAAW,EAAE,CAAC;CACtB;AAED;;;;iEAIiE;AACjE,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,WAAW,EAAE,CAAC;CACtB;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,6 @@
1
1
  {
2
2
  "name": "@telorun/kernel",
3
- "version": "0.55.0",
3
+ "version": "0.57.0",
4
4
  "description": "Telo Runtime - A lightweight, polyglot execution host.",
5
5
  "keywords": [
6
6
  "telo",
@@ -61,7 +61,7 @@
61
61
  "dependencies": {
62
62
  "@marcbachmann/cel-js": "^7.6.1",
63
63
  "@sinclair/typebox": "^0.34.48",
64
- "@telorun/analyzer": "0.43.0",
64
+ "@telorun/analyzer": "0.45.0",
65
65
  "@telorun/glob": "0.2.0",
66
66
  "@telorun/templating": "0.11.0",
67
67
  "ajv": "^8.17.1",
@@ -75,7 +75,7 @@
75
75
  "@types/tar-stream": "^3.1.3",
76
76
  "typescript": "^5.0.0",
77
77
  "vitest": "^2.1.8",
78
- "@telorun/sdk": "0.54.0"
78
+ "@telorun/sdk": "0.56.0"
79
79
  },
80
80
  "optionalDependencies": {
81
81
  "esbuild": "^0.28.1"
@@ -21,7 +21,6 @@ export function findOwnerDoc(docs: Document[]): Document | undefined {
21
21
  /** The owner-doc fields the transports read: identity for the publish location,
22
22
  * and payload markers for artifact fetch. */
23
23
  export interface OwnerManifest {
24
- namespace?: string;
25
24
  name?: string;
26
25
  version?: string;
27
26
  filesIntegrity?: string;
@@ -36,8 +35,8 @@ export interface OwnerManifest {
36
35
  }
37
36
 
38
37
  /** Read the owner doc's identity + payload fields from a manifest, parsing once
39
- * (never regex-scraping). The single source both transports call for
40
- * `<namespace>/<name>/<version>`, `filesIntegrity`, and payload detection. */
38
+ * (never regex-scraping). The single source both transports call for the
39
+ * module's name and version, `filesIntegrity`, and payload detection. */
41
40
  export function readOwnerManifest(text: string): OwnerManifest {
42
41
  const owner = findOwnerDoc(parseManifestDocs(text));
43
42
  const parsed = owner?.toJSON() as
@@ -46,7 +45,6 @@ export function readOwnerManifest(text: string): OwnerManifest {
46
45
  const md = parsed?.metadata ?? {};
47
46
  const str = (v: unknown): string | undefined => (typeof v === "string" ? v : undefined);
48
47
  return {
49
- namespace: str(md.namespace),
50
48
  name: str(md.name),
51
49
  version: str(md.version),
52
50
  filesIntegrity: str(parsed?.filesIntegrity),
package/src/kernel.ts CHANGED
@@ -445,9 +445,11 @@ export class Kernel implements IKernel {
445
445
  const staticManifests = flattenForAnalyzer(analysisGraph);
446
446
  this.staticManifests = staticManifests;
447
447
 
448
- // Register module identities for x-telo-ref resolution (Phase 3 prerequisite).
449
- // Telo built-ins ("telo" "Telo") are auto-registered when Telo.Abstract
450
- // definitions are registered in loadBuiltinDefinitions() above.
448
+ // Register legacy module identities so an already-published module version
449
+ // whose `x-telo-ref` slots still name their target as
450
+ // `<namespace>/<module>#<Kind>` keeps resolving. Current manifests declare no
451
+ // namespace and need none — their constraints name an import alias, which
452
+ // the analyzer canonicalizes in the declaring module's scope.
451
453
  const rootModuleDoc = staticManifests.find((m) => isModuleKind(m.kind));
452
454
  if (rootModuleDoc?.kind === "Telo.Library") {
453
455
  throw new RuntimeError(
@@ -58,7 +58,7 @@ const throwsSchema = {
58
58
  /** Alias-form pattern for `extends` values: "<Alias>.<AbstractName>".
59
59
  * Resolved against the declaring file's `Telo.Import` aliases — identical to how
60
60
  * kind prefixes work (e.g. `kind: Http.Api` resolves `Http` via the importer's
61
- * alias registration). Identity form (`std/mod#Name`) is intentionally not
61
+ * alias registration). Identity form (`std/mod#Name`) is deprecated and intentionally not
62
62
  * accepted: aliases carry the module version via their `Telo.Import` source,
63
63
  * which canonical module names can't.
64
64
  * - Alias: PascalCase (first letter uppercase)
@@ -1,4 +1,10 @@
1
- import { splitIntegrity, verifyIntegrity, type LoadedGraph, type ManifestSource } from "@telorun/analyzer";
1
+ import {
2
+ manifestCacheKey,
3
+ splitIntegrity,
4
+ verifyIntegrity,
5
+ type LoadedGraph,
6
+ type ManifestSource,
7
+ } from "@telorun/analyzer";
2
8
  import { statSync } from "fs";
3
9
  import * as fs from "fs/promises";
4
10
  import * as path from "path";
@@ -27,8 +33,9 @@ function joinUnder(root: string, ...segments: string[]): string | null {
27
33
  /** Single source of truth for URL → cache path. Used identically by the
28
34
  * reader (cache lookup) and writer (install-time persistence). For any
29
35
  * given import ref — registry ref, direct registry URL, arbitrary HTTP, or
30
- * (once registered) `oci://` — both sides land on the same file, because the
31
- * owning transport decides the layout via {@link Transport.cacheLocation}.
36
+ * `oci://` — both sides land on the same file: the owning transport supplies
37
+ * the coordinates and the analyzer's `manifestCacheKey` renders them, the same
38
+ * grammar the hub's static manifest bucket and the editor's read path use.
32
39
  *
33
40
  * Returns `null` for unsupported refs (file://, memory://, relative paths) or
34
41
  * for path-traversal attempts that would escape `cacheRoot`. */
@@ -37,9 +44,11 @@ function cachePathForUrl(
37
44
  cacheRoot: string,
38
45
  transports: TransportRegistry,
39
46
  ): string | null {
40
- const segments = transports.cacheLocation(rawUrl);
41
- if (!segments) return null;
42
- return joinUnder(cacheRoot, ...segments);
47
+ const coords = transports.cacheCoords(rawUrl);
48
+ if (!coords) return null;
49
+ const key = manifestCacheKey(coords);
50
+ if (!key) return null;
51
+ return joinUnder(cacheRoot, ...key.split("/"));
43
52
  }
44
53
 
45
54
  /**
@@ -1,4 +1,11 @@
1
1
  // The OCI ref grammar is pure string parsing shared with the browser-safe
2
2
  // manifest-cache key helper, so it lives in `@telorun/analyzer`; this shim
3
3
  // keeps the kernel-internal import sites stable.
4
- export { OCI_SCHEME, isOciRef, parseOciRef, type ParsedOciRef } from "@telorun/analyzer";
4
+ export {
5
+ OCI_SCHEME,
6
+ isOciRef,
7
+ parseOciRef,
8
+ parseVersionedRef,
9
+ withRefVersion,
10
+ type ParsedOciRef,
11
+ } from "@telorun/analyzer";
@@ -2,8 +2,8 @@ import {
2
2
  DEFAULT_MANIFEST_FILENAME,
3
3
  IntegrityError,
4
4
  sha256Base64Url,
5
- splitIntegrity,
6
5
  verifyIntegrity,
6
+ type ManifestCacheCoords,
7
7
  type ManifestSource,
8
8
  } from "@telorun/analyzer";
9
9
 
@@ -15,7 +15,6 @@ import type {
15
15
  PublishBundle,
16
16
  PublishOptions,
17
17
  PublishResult,
18
- SiblingIdentity,
19
18
  Transport,
20
19
  } from "../transport.js";
21
20
  import {
@@ -24,7 +23,13 @@ import {
24
23
  TELO_LAYER_MEDIA_TYPE,
25
24
  type OciManifest,
26
25
  } from "./oci-client.js";
27
- import { OCI_SCHEME, isOciRef, parseOciRef } from "./oci-ref.js";
26
+ import {
27
+ OCI_SCHEME,
28
+ isOciRef,
29
+ parseOciRef,
30
+ parseVersionedRef,
31
+ withRefVersion,
32
+ } from "./oci-ref.js";
28
33
 
29
34
  /** Pull the module blob, returning its extracted entries and the `telo.yaml`
30
35
  * bytes, verified against the ref's inline hash and its own `filesIntegrity`. */
@@ -97,14 +102,23 @@ export class OciTransport implements Transport {
97
102
  return isOciRef(ref);
98
103
  }
99
104
 
100
- cacheLocation(ref: string): string[] | null {
105
+ /** Keyed by the ref's reference a tag, or a `sha256:` digest, or the
106
+ * implicit `latest` — so every resolvable ref stays cacheable. (The hub's
107
+ * `ociManifestCacheCoords` refuses everything but an explicit tag; that is a
108
+ * discovery-index rule, not a property of the key grammar.) */
109
+ cacheCoords(ref: string): ManifestCacheCoords | null {
101
110
  let parsed: ReturnType<typeof parseOciRef>;
102
111
  try {
103
112
  parsed = parseOciRef(ref);
104
113
  } catch {
105
114
  return null;
106
115
  }
107
- return ["__oci", parsed.host, ...parsed.repo.split("/"), parsed.reference];
116
+ return {
117
+ transport: "oci",
118
+ host: parsed.host,
119
+ path: parsed.repo,
120
+ version: parsed.reference,
121
+ };
108
122
  }
109
123
 
110
124
  /** Resolve a relative import against an `oci://` base, normalizing the repo to
@@ -130,16 +144,14 @@ export class OciTransport implements Transport {
130
144
  refVersion(ref: string): string | null {
131
145
  // The reference (tag or `sha256:` digest) is what `@` separates. An implicit
132
146
  // `latest` (no `@`) is not an upgradeable pin, so return null there; a digest
133
- // reference flows through raw and the caller's SemVer check skips it.
134
- const { base } = splitIntegrity(ref);
135
- if (!base.startsWith(OCI_SCHEME)) return null;
136
- const at = base.lastIndexOf("@");
137
- return at > 0 ? base.slice(at + 1) : null;
147
+ // reference flows through raw and the caller's SemVer check skips it. The
148
+ // split itself is the shared grammar — the editor reads the same pin from a
149
+ // browser, where no transport exists.
150
+ return isOciRef(ref) ? (parseVersionedRef(ref)?.version ?? null) : null;
138
151
  }
139
152
 
140
153
  withVersion(ref: string, version: string): string {
141
- const { host, repo } = parseOciRef(ref);
142
- return `${OCI_SCHEME}${host}/${repo}@${version}`;
154
+ return withRefVersion(ref, version);
143
155
  }
144
156
 
145
157
  async digest(ref: string): Promise<string | null> {
@@ -240,10 +252,10 @@ export class OciTransport implements Transport {
240
252
  canonicalizeSiblingRef(
241
253
  destination: string,
242
254
  relativeSource: string,
243
- sibling: SiblingIdentity,
255
+ version: string,
244
256
  ): string {
245
257
  // The sibling's repo is the destination repo with the relative applied; the
246
258
  // version is its own (identity is the ref, not metadata).
247
- return `${this.resolveRelative(destination, relativeSource)}@${sibling.version}`;
259
+ return `${this.resolveRelative(destination, relativeSource)}@${version}`;
248
260
  }
249
261
  }