@elaraai/e3-types 1.0.79 → 1.0.80

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 (153) hide show
  1. package/README.md +1 -1
  2. package/dist/src/api.d.ts +569 -36
  3. package/dist/src/api.d.ts.map +1 -1
  4. package/dist/src/api.js +257 -32
  5. package/dist/src/api.js.map +1 -1
  6. package/dist/src/collection-manifest.d.ts +37 -0
  7. package/dist/src/collection-manifest.d.ts.map +1 -0
  8. package/dist/src/collection-manifest.js +37 -0
  9. package/dist/src/collection-manifest.js.map +1 -0
  10. package/dist/src/dataflow.d.ts +264 -19
  11. package/dist/src/dataflow.d.ts.map +1 -1
  12. package/dist/src/dataflow.js +156 -15
  13. package/dist/src/dataflow.js.map +1 -1
  14. package/dist/src/dataflow.spec.js +184 -27
  15. package/dist/src/dataflow.spec.js.map +1 -1
  16. package/dist/src/dataset-blob.d.ts +75 -15
  17. package/dist/src/dataset-blob.d.ts.map +1 -1
  18. package/dist/src/dataset-blob.js +95 -28
  19. package/dist/src/dataset-blob.js.map +1 -1
  20. package/dist/src/dataset-blob.spec.d.ts +6 -0
  21. package/dist/src/dataset-blob.spec.d.ts.map +1 -0
  22. package/dist/src/dataset-blob.spec.js +92 -0
  23. package/dist/src/dataset-blob.spec.js.map +1 -0
  24. package/dist/src/dataset-ref.d.ts +5 -4
  25. package/dist/src/dataset-ref.d.ts.map +1 -1
  26. package/dist/src/dataset-ref.js +5 -4
  27. package/dist/src/dataset-ref.js.map +1 -1
  28. package/dist/src/environment.d.ts +3 -2
  29. package/dist/src/environment.d.ts.map +1 -1
  30. package/dist/src/environment.js +3 -2
  31. package/dist/src/environment.js.map +1 -1
  32. package/dist/src/execution.d.ts +112 -18
  33. package/dist/src/execution.d.ts.map +1 -1
  34. package/dist/src/execution.js +174 -45
  35. package/dist/src/execution.js.map +1 -1
  36. package/dist/src/execution.spec.d.ts +6 -0
  37. package/dist/src/execution.spec.d.ts.map +1 -0
  38. package/dist/src/execution.spec.js +108 -0
  39. package/dist/src/execution.spec.js.map +1 -0
  40. package/dist/src/function.d.ts +14 -12
  41. package/dist/src/function.d.ts.map +1 -1
  42. package/dist/src/function.js +17 -32
  43. package/dist/src/function.js.map +1 -1
  44. package/dist/src/index.d.ts +16 -12
  45. package/dist/src/index.d.ts.map +1 -1
  46. package/dist/src/index.js +25 -20
  47. package/dist/src/index.js.map +1 -1
  48. package/dist/src/lock.d.ts +68 -22
  49. package/dist/src/lock.d.ts.map +1 -1
  50. package/dist/src/lock.js +33 -22
  51. package/dist/src/lock.js.map +1 -1
  52. package/dist/src/names.d.ts +21 -0
  53. package/dist/src/names.d.ts.map +1 -0
  54. package/dist/src/names.js +31 -0
  55. package/dist/src/names.js.map +1 -0
  56. package/dist/src/package.d.ts +11 -78
  57. package/dist/src/package.d.ts.map +1 -1
  58. package/dist/src/package.js +13 -66
  59. package/dist/src/package.js.map +1 -1
  60. package/dist/src/record.d.ts +582 -18
  61. package/dist/src/record.d.ts.map +1 -1
  62. package/dist/src/record.js +405 -7
  63. package/dist/src/record.js.map +1 -1
  64. package/dist/src/{stream.spec.d.ts → record.spec.d.ts} +1 -1
  65. package/dist/src/record.spec.d.ts.map +1 -0
  66. package/dist/src/record.spec.js +143 -0
  67. package/dist/src/record.spec.js.map +1 -0
  68. package/dist/src/release.d.ts +36 -0
  69. package/dist/src/release.d.ts.map +1 -0
  70. package/dist/src/release.js +71 -0
  71. package/dist/src/release.js.map +1 -0
  72. package/dist/src/release.spec.d.ts +6 -0
  73. package/dist/src/release.spec.d.ts.map +1 -0
  74. package/dist/src/release.spec.js +42 -0
  75. package/dist/src/release.spec.js.map +1 -0
  76. package/dist/src/repository.d.ts +64 -0
  77. package/dist/src/repository.d.ts.map +1 -0
  78. package/dist/src/repository.js +49 -0
  79. package/dist/src/repository.js.map +1 -0
  80. package/dist/src/runner.d.ts +16 -62
  81. package/dist/src/runner.d.ts.map +1 -1
  82. package/dist/src/runner.js +16 -79
  83. package/dist/src/runner.js.map +1 -1
  84. package/dist/src/runner.spec.js +11 -85
  85. package/dist/src/runner.spec.js.map +1 -1
  86. package/dist/src/structure.d.ts +0 -57
  87. package/dist/src/structure.d.ts.map +1 -1
  88. package/dist/src/structure.js +0 -3
  89. package/dist/src/structure.js.map +1 -1
  90. package/dist/src/task.d.ts +210 -318
  91. package/dist/src/task.d.ts.map +1 -1
  92. package/dist/src/task.js +117 -472
  93. package/dist/src/task.js.map +1 -1
  94. package/dist/src/task.spec.js +62 -154
  95. package/dist/src/task.spec.js.map +1 -1
  96. package/dist/src/transfer.d.ts +16 -22
  97. package/dist/src/transfer.d.ts.map +1 -1
  98. package/dist/src/transfer.js +16 -22
  99. package/dist/src/transfer.js.map +1 -1
  100. package/dist/src/transfer.spec.js +4 -34
  101. package/dist/src/transfer.spec.js.map +1 -1
  102. package/dist/src/unit-plan.d.ts +130 -0
  103. package/dist/src/unit-plan.d.ts.map +1 -0
  104. package/dist/src/unit-plan.js +107 -0
  105. package/dist/src/unit-plan.js.map +1 -0
  106. package/dist/src/unit-plan.spec.d.ts +6 -0
  107. package/dist/src/unit-plan.spec.d.ts.map +1 -0
  108. package/dist/src/unit-plan.spec.js +29 -0
  109. package/dist/src/unit-plan.spec.js.map +1 -0
  110. package/dist/src/workspace.d.ts +22 -11
  111. package/dist/src/workspace.d.ts.map +1 -1
  112. package/dist/src/workspace.js +10 -11
  113. package/dist/src/workspace.js.map +1 -1
  114. package/package.json +3 -3
  115. package/src/api.ts +276 -32
  116. package/src/collection-manifest.ts +53 -0
  117. package/src/dataflow.spec.ts +223 -31
  118. package/src/dataflow.ts +183 -26
  119. package/src/dataset-blob.spec.ts +117 -0
  120. package/src/dataset-blob.ts +157 -21
  121. package/src/dataset-ref.ts +5 -4
  122. package/src/environment.ts +3 -2
  123. package/src/execution.spec.ts +114 -0
  124. package/src/execution.ts +175 -51
  125. package/src/function.ts +19 -32
  126. package/src/index.ts +122 -39
  127. package/src/lock.ts +39 -22
  128. package/src/names.ts +39 -0
  129. package/src/package.ts +15 -71
  130. package/src/record.spec.ts +195 -0
  131. package/src/record.ts +489 -7
  132. package/src/release.spec.ts +47 -0
  133. package/src/release.ts +69 -0
  134. package/src/repository.ts +67 -0
  135. package/src/runner.spec.ts +11 -94
  136. package/src/runner.ts +16 -80
  137. package/src/structure.ts +0 -8
  138. package/src/task.spec.ts +67 -188
  139. package/src/task.ts +140 -522
  140. package/src/transfer.spec.ts +4 -51
  141. package/src/transfer.ts +16 -22
  142. package/src/unit-plan.spec.ts +31 -0
  143. package/src/unit-plan.ts +121 -0
  144. package/src/workspace.ts +13 -11
  145. package/dist/src/stream.d.ts +0 -97
  146. package/dist/src/stream.d.ts.map +0 -1
  147. package/dist/src/stream.js +0 -134
  148. package/dist/src/stream.js.map +0 -1
  149. package/dist/src/stream.spec.d.ts.map +0 -1
  150. package/dist/src/stream.spec.js +0 -60
  151. package/dist/src/stream.spec.js.map +0 -1
  152. package/src/stream.spec.ts +0 -88
  153. package/src/stream.ts +0 -170
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * The release of e3 this build is, and how two releases order.
7
+ *
8
+ * @remarks
9
+ * A release is the version the release scripts write into every package.
10
+ * `scripts/set-npm-version.mjs` writes it here with them, and
11
+ * `scripts/check-version-drift.mjs` refuses a tree where it differs from
12
+ * theirs. What e3 keeps or ships records the release that wrote it: a
13
+ * repository's record, an execution state and a package zip, and a transfer
14
+ * request the release that sent it, so a refusal of any of them names that
15
+ * release beside this one.
16
+ */
17
+ /** The release of e3 this build is. */
18
+ export declare const E3_RELEASE = "1.0.79";
19
+ /**
20
+ * Orders two releases by semantic-version precedence.
21
+ *
22
+ * @remarks
23
+ * The core, `major.minor.patch`, orders numerically. A pre-release
24
+ * (`1.1.0-beta.2`) precedes the release of its core, and two pre-releases of
25
+ * one core order by their dot-separated identifiers in turn: numbers
26
+ * numerically and before words, words in ASCII order, and a list that is a
27
+ * prefix of the other first. Build metadata (`+…`) orders nothing.
28
+ *
29
+ * @param a - A release, such as `1.0.79` or `1.1.0-beta.2`
30
+ * @param b - Another release
31
+ * @returns A negative number when `a` precedes `b`, a positive one when it
32
+ * follows it, and 0 when neither does
33
+ * @throws {Error} When either is not a semantic version
34
+ */
35
+ export declare function compareReleases(a: string, b: string): number;
36
+ //# sourceMappingURL=release.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"release.d.ts","sourceRoot":"","sources":["../../src/release.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;GAWG;AAEH,uCAAuC;AACvC,eAAO,MAAM,UAAU,WAAW,CAAC;AAKnC;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAkB5D"}
@@ -0,0 +1,71 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * The release of e3 this build is, and how two releases order.
7
+ *
8
+ * @remarks
9
+ * A release is the version the release scripts write into every package.
10
+ * `scripts/set-npm-version.mjs` writes it here with them, and
11
+ * `scripts/check-version-drift.mjs` refuses a tree where it differs from
12
+ * theirs. What e3 keeps or ships records the release that wrote it: a
13
+ * repository's record, an execution state and a package zip, and a transfer
14
+ * request the release that sent it, so a refusal of any of them names that
15
+ * release beside this one.
16
+ */
17
+ /** The release of e3 this build is. */
18
+ export const E3_RELEASE = '1.0.79';
19
+ /** A semantic version: its core, a pre-release, and build metadata. */
20
+ const RELEASE = /^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/;
21
+ /**
22
+ * Orders two releases by semantic-version precedence.
23
+ *
24
+ * @remarks
25
+ * The core, `major.minor.patch`, orders numerically. A pre-release
26
+ * (`1.1.0-beta.2`) precedes the release of its core, and two pre-releases of
27
+ * one core order by their dot-separated identifiers in turn: numbers
28
+ * numerically and before words, words in ASCII order, and a list that is a
29
+ * prefix of the other first. Build metadata (`+…`) orders nothing.
30
+ *
31
+ * @param a - A release, such as `1.0.79` or `1.1.0-beta.2`
32
+ * @param b - Another release
33
+ * @returns A negative number when `a` precedes `b`, a positive one when it
34
+ * follows it, and 0 when neither does
35
+ * @throws {Error} When either is not a semantic version
36
+ */
37
+ export function compareReleases(a, b) {
38
+ const x = parseRelease(a);
39
+ const y = parseRelease(b);
40
+ for (let i = 0; i < 3; i++) {
41
+ if (x.core[i] !== y.core[i])
42
+ return x.core[i] < y.core[i] ? -1 : 1;
43
+ }
44
+ if (x.pre.length === 0 || y.pre.length === 0)
45
+ return y.pre.length - x.pre.length;
46
+ for (let i = 0; i < Math.min(x.pre.length, y.pre.length); i++) {
47
+ const p = x.pre[i];
48
+ const q = y.pre[i];
49
+ if (p === q)
50
+ continue;
51
+ const pNumber = /^\d+$/.test(p);
52
+ const qNumber = /^\d+$/.test(q);
53
+ if (pNumber && qNumber)
54
+ return BigInt(p) < BigInt(q) ? -1 : 1;
55
+ if (pNumber !== qNumber)
56
+ return pNumber ? -1 : 1;
57
+ return p < q ? -1 : 1;
58
+ }
59
+ return x.pre.length - y.pre.length;
60
+ }
61
+ /** A release's core numbers and pre-release identifiers. */
62
+ function parseRelease(release) {
63
+ const match = RELEASE.exec(release);
64
+ if (match === null)
65
+ throw new Error(`${JSON.stringify(release)} is not a release: a release is a semantic version, such as ${E3_RELEASE}`);
66
+ return {
67
+ core: [Number(match[1]), Number(match[2]), Number(match[3])],
68
+ pre: match[4] === undefined ? [] : match[4].split('.'),
69
+ };
70
+ }
71
+ //# sourceMappingURL=release.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"release.js","sourceR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
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=release.spec.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"release.spec.d.ts","sourceRoot":"","sources":["../../src/release.spec.ts"],"names":[],"mappings":"AAAA;;;GAGG"}
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * The order of releases, by which an e3 tells a newer release's zip or
7
+ * execution state from an older one's.
8
+ */
9
+ import { describe, it } from 'node:test';
10
+ import assert from 'node:assert/strict';
11
+ import { E3_RELEASE, compareReleases } from './release.js';
12
+ describe('compareReleases', () => {
13
+ it('orders releases by semantic-version precedence', () => {
14
+ // Each precedes the next: the core numerically, a pre-release before its
15
+ // core's release, numeric identifiers before words and numerically, and a
16
+ // list before a longer one it begins.
17
+ const ordered = [
18
+ '0.9.0', '1.0.0-alpha', '1.0.0-alpha.1', '1.0.0-alpha.beta', '1.0.0-beta', '1.0.0-beta.2', '1.0.0-beta.11',
19
+ '1.0.0-rc.1', '1.0.0', '1.0.9', '1.0.10', '1.0.79', '1.0.80-beta.1', '1.0.80', '1.1.0', '2.0.0',
20
+ ];
21
+ for (let i = 0; i < ordered.length; i++) {
22
+ for (let j = 0; j < ordered.length; j++) {
23
+ const order = Math.sign(compareReleases(ordered[i], ordered[j]));
24
+ assert.equal(order, Math.sign(i - j), `${ordered[i]} against ${ordered[j]}`);
25
+ }
26
+ }
27
+ });
28
+ it('orders nothing by build metadata', () => {
29
+ assert.equal(compareReleases('1.0.79+ci.7', '1.0.79'), 0);
30
+ assert.equal(compareReleases('1.0.80-beta.1+a', '1.0.80-beta.1+b'), 0);
31
+ });
32
+ it('refuses what is not a semantic version, naming it', () => {
33
+ for (const release of ['1.0', 'v1.0.79', '1.0.079', '1.0.79-', 'latest', '']) {
34
+ assert.throws(() => compareReleases(release, E3_RELEASE), { message: new RegExp(`^${JSON.stringify(release).replace(/[.+]/g, '\\$&')} is not a release`) });
35
+ assert.throws(() => compareReleases(E3_RELEASE, release), /is not a release/);
36
+ }
37
+ });
38
+ it('is a release itself', () => {
39
+ assert.equal(compareReleases(E3_RELEASE, E3_RELEASE), 0);
40
+ });
41
+ });
42
+ //# sourceMappingURL=release.spec.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"release.spec.js","sourceRoot":"","sources":["../../src/release.spec.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;GAGG;AAEH,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,MAAM,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAE3D,QAAQ,CAAC,iBAAiB,EAAE,GAAG,EAAE;IAC/B,EAAE,CAAC,gDAAgD,EAAE,GAAG,EAAE;QACxD,yEAAyE;QACzE,0EAA0E;QAC1E,sCAAsC;QACtC,MAAM,OAAO,GAAG;YACd,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,kBAAkB,EAAE,YAAY,EAAE,cAAc,EAAE,eAAe;YAC1G,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,eAAe,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO;SAChG,CAAC;QACF,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YACxC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACxC,MAAM,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,C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;IAC3D,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,64 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * A repository's own records: the record of the forms it keeps — the release
7
+ * of e3 that last wrote it, and the store upgrades it has had — and its
8
+ * metadata: its name, its lifecycle status and when each began.
9
+ */
10
+ import { ArrayType, VariantType, StructType, StringType, DateTimeType, NullType, ValueTypeOf } from '@elaraai/east';
11
+ /**
12
+ * The repository record: the release of e3 that last wrote it, and the store
13
+ * upgrades the repository has had, which an e3 opening it reads before
14
+ * anything else.
15
+ */
16
+ export declare const RepositoryRecordType: StructType<{
17
+ /** The release of e3 that last wrote the record */
18
+ readonly release: StringType;
19
+ /** The store upgrades the repository has had, in the order they were
20
+ * applied: each by its name, with the release of e3 that applied it */
21
+ readonly upgrades: ArrayType<StructType<{
22
+ readonly name: StringType;
23
+ readonly release: StringType;
24
+ }>>;
25
+ }>;
26
+ export type RepositoryRecord = ValueTypeOf<typeof RepositoryRecordType>;
27
+ /**
28
+ * Where a repository is in its lifecycle.
29
+ */
30
+ export declare const RepoStatusType: VariantType<{
31
+ /** Being initialised */
32
+ readonly creating: NullType;
33
+ /** Ready for use */
34
+ readonly active: NullType;
35
+ /** A garbage collection is running */
36
+ readonly gc: NullType;
37
+ /** Being deleted */
38
+ readonly deleting: NullType;
39
+ }>;
40
+ export type RepoStatus = ValueTypeOf<typeof RepoStatusType>;
41
+ /**
42
+ * A repository's metadata.
43
+ */
44
+ export declare const RepoMetadataType: StructType<{
45
+ /** The repository's name */
46
+ readonly name: StringType;
47
+ /** Where it is in its lifecycle */
48
+ readonly status: VariantType<{
49
+ /** Being initialised */
50
+ readonly creating: NullType;
51
+ /** Ready for use */
52
+ readonly active: NullType;
53
+ /** A garbage collection is running */
54
+ readonly gc: NullType;
55
+ /** Being deleted */
56
+ readonly deleting: NullType;
57
+ }>;
58
+ /** When it was created */
59
+ readonly createdAt: DateTimeType;
60
+ /** When its status last changed */
61
+ readonly statusChangedAt: DateTimeType;
62
+ }>;
63
+ export type RepoMetadata = ValueTypeOf<typeof RepoMetadataType>;
64
+ //# sourceMappingURL=repository.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"repository.d.ts","sourceRoot":"","sources":["../../src/repository.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,WAAW,EACX,UAAU,EACV,UAAU,EACV,YAAY,EACZ,QAAQ,EACR,WAAW,EACZ,MAAM,eAAe,CAAC;AAEvB;;;;GAIG;AACH,eAAO,MAAM,oBAAoB;IAC/B,mDAAmD;;IAEnD;4EACwE;;;;;EAExE,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAExE;;GAEG;AACH,eAAO,MAAM,cAAc;IACzB,wBAAwB;;IAExB,oBAAoB;;IAEpB,sCAAsC;;IAEtC,oBAAoB;;EAEpB,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,WAAW,CAAC,OAAO,cAAc,CAAC,CAAC;AAE5D;;GAEG;AACH,eAAO,MAAM,gBAAgB;IAC3B,4BAA4B;;IAE5B,mCAAmC;;QAlBnC,wBAAwB;;QAExB,oBAAoB;;QAEpB,sCAAsC;;QAEtC,oBAAoB;;;IAcpB,0BAA0B;;IAE1B,mCAAmC;;EAEnC,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,WAAW,CAAC,OAAO,gBAAgB,CAAC,CAAC"}
@@ -0,0 +1,49 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * A repository's own records: the record of the forms it keeps — the release
7
+ * of e3 that last wrote it, and the store upgrades it has had — and its
8
+ * metadata: its name, its lifecycle status and when each began.
9
+ */
10
+ import { ArrayType, VariantType, StructType, StringType, DateTimeType, NullType, } from '@elaraai/east';
11
+ /**
12
+ * The repository record: the release of e3 that last wrote it, and the store
13
+ * upgrades the repository has had, which an e3 opening it reads before
14
+ * anything else.
15
+ */
16
+ export const RepositoryRecordType = StructType({
17
+ /** The release of e3 that last wrote the record */
18
+ release: StringType,
19
+ /** The store upgrades the repository has had, in the order they were
20
+ * applied: each by its name, with the release of e3 that applied it */
21
+ upgrades: ArrayType(StructType({ name: StringType, release: StringType })),
22
+ });
23
+ /**
24
+ * Where a repository is in its lifecycle.
25
+ */
26
+ export const RepoStatusType = VariantType({
27
+ /** Being initialised */
28
+ creating: NullType,
29
+ /** Ready for use */
30
+ active: NullType,
31
+ /** A garbage collection is running */
32
+ gc: NullType,
33
+ /** Being deleted */
34
+ deleting: NullType,
35
+ });
36
+ /**
37
+ * A repository's metadata.
38
+ */
39
+ export const RepoMetadataType = StructType({
40
+ /** The repository's name */
41
+ name: StringType,
42
+ /** Where it is in its lifecycle */
43
+ status: RepoStatusType,
44
+ /** When it was created */
45
+ createdAt: DateTimeType,
46
+ /** When its status last changed */
47
+ statusChangedAt: DateTimeType,
48
+ });
49
+ //# sourceMappingURL=repository.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"repository.js","sourceRoot":"","sources":["../../src/repository.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EACL,SAAS,EACT,WAAW,EACX,UAAU,EACV,UAAU,EACV,YAAY,EACZ,QAAQ,GAET,MAAM,eAAe,CAAC;AAEvB;;;;GAIG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,UAAU,CAAC;IAC7C,mDAAmD;IACnD,OAAO,EAAE,UAAU;IACnB;4EACwE;IACxE,QAAQ,EAAE,SAAS,CAAC,UAAU,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,CAAC,CAAC;CAC3E,CAAC,CAAC;AAIH;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,WAAW,CAAC;IACxC,wBAAwB;IACxB,QAAQ,EAAE,QAAQ;IAClB,oBAAoB;IACpB,MAAM,EAAE,QAAQ;IAChB,sCAAsC;IACtC,EAAE,EAAE,QAAQ;IACZ,oBAAoB;IACpB,QAAQ,EAAE,QAAQ;CACnB,CAAC,CAAC;AAIH;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,UAAU,CAAC;IACzC,4BAA4B;IAC5B,IAAI,EAAE,UAAU;IAChB,mCAAmC;IACnC,MAAM,EAAE,cAAc;IACtB,0BAA0B;IAC1B,SAAS,EAAE,YAAY;IACvB,mCAAmC;IACnC,eAAe,EAAE,YAAY;CAC9B,CAAC,CAAC"}
@@ -3,29 +3,23 @@
3
3
  * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
4
  */
5
5
  /**
6
- * Runner wire types for e3 functions.
6
+ * Runner wire types for e3 tasks, functions and records.
7
7
  *
8
- * `RunnerType` is the wire image of the SDK's `Runner` union (minus its
9
- * `custom` raw-argv runtime — see the security note below). It pins the
10
- * executable to a known runtime for every tag, so a function call can never
11
- * name its own executable; only platform flags vary.
12
- *
13
- * A `platforms` entry is just a `-p <name>` flag on the wire; the SDK's
14
- * `Platform<Known> | { custom }` distinction is authoring sugar that
15
- * collapses to a string.
8
+ * `RunnerType` is the wire image of the SDK's `Runner` union. A known-runtime
9
+ * tag pins the executable to one of the stock runners, which runs units through
10
+ * its `exec` command; `custom` names a command of the author's own.
16
11
  */
17
12
  import { VariantType, StructType, ArrayType, StringType, ValueTypeOf } from '@elaraai/east';
18
13
  /**
19
- * Wire representation of a runner — shared by tasks and functions
20
- * (symmetric: both carry `runner: RunnerType`).
21
- *
22
- * The known-runtime tags name a runtime binary; `platforms` are passed as
23
- * `-p` flags. `custom` carries a raw argv prefix: for functions it is the
24
- * executed command (the standard `-i/-o/<ir>` suffix is appended, so the
25
- * command must speak the runner CLI convention); for tasks it is routing
26
- * metadata only — a task's `commandIr` remains authoritative for execution.
27
- * Package authors can already execute arbitrary commands via custom tasks,
28
- * so `custom` grants no capability that tasks don't have.
14
+ * Wire representation of a runner — shared by tasks, functions and records.
15
+ *
16
+ * A known-runtime tag names a stock runner, and `platforms` names the platform
17
+ * packages the units it runs load. `custom` carries a command, which e3 runs
18
+ * with the arguments of a stock runner's `run`: `-i` for each input, `-o` for
19
+ * the output, then the program's file. A custom task's body is its own
20
+ * command, and its runner's is empty. Package authors can already execute
21
+ * arbitrary commands via custom tasks, so `custom` grants no capability that
22
+ * tasks don't have.
29
23
  */
30
24
  export declare const RunnerType: VariantType<{
31
25
  readonly east_node: StructType<{
@@ -43,45 +37,6 @@ export declare const RunnerType: VariantType<{
43
37
  }>;
44
38
  export type RunnerType = typeof RunnerType;
45
39
  export type RunnerValue = ValueTypeOf<typeof RunnerType>;
46
- /**
47
- * Resolve a {@link RunnerType} value to the argv prefix of one of its
48
- * commands (the wire-value analogue of the SDK's `runnerToCommand`): `run`,
49
- * the default — `[<bin>, 'run', -p…]` — or `merge`, the blob merge every
50
- * stock runner ships — `[<bin>, 'merge', -p…]`, the fan-in of a partitioned
51
- * task's keyed partials (issue #770). Lives in e3-types so both e3-core
52
- * (local) and the cloud execution kernel import the one resolver.
53
- *
54
- * Variant tags use underscores (`east_node`) mapped to the binary name
55
- * (`east-node`) here. A `custom` runner's command is its `run`; it has no
56
- * merge command.
57
- *
58
- * @param r - the runner
59
- * @param command - the runner command, `run` by default
60
- * @returns the argv prefix
61
- * @throws {Error} When `merge` is asked of a custom runner.
62
- */
63
- export declare function runnerToArgv(r: RunnerValue, command?: 'run' | 'merge'): string[];
64
- /**
65
- * Insert the runner's `-v/--verbose` flag into a fully-built argv, for the
66
- * known runtimes only.
67
- *
68
- * All three known runners (`east-node`/`east-py`/`east-c`, `run` and `merge`)
69
- * accept `-v` among their options and print timing/perf detail to stderr; a
70
- * `custom` runner's argv is user-authored, so a flag is never spliced into
71
- * it. A known-runtime argv always starts `[<bin>, <command>, …]` (see
72
- * {@link runnerToArgv} and the SDK's `runnerToCommand`), so `-v` goes at
73
- * index 2 — ahead of the `-p`/`-i`/`-o` flags and the trailing IR path.
74
- *
75
- * This is a pure **runtime** toggle: it is applied to the *evaluated* argv
76
- * immediately before spawn and never touches the task's `commandIr`, the
77
- * {@link RunnerType}, or any hash — so it cannot affect caching.
78
- *
79
- * @param runner - the runner the argv was built for (gates the injection)
80
- * @param args - the fully-built argv (runner prefix + `-i`/`-o`/`<ir>` suffix)
81
- * @param verbose - when true, request the runner's verbose output
82
- * @returns the argv, with `-v` inserted for known runtimes when verbose
83
- */
84
- export declare function withRunnerVerbose(runner: RunnerValue, args: string[], verbose?: boolean): string[];
85
40
  /**
86
41
  * Insert the runner's `--exit-with-parent` flag into a fully-built argv, for
87
42
  * the known runtimes only — the stdin lifeline (issue #770).
@@ -89,10 +44,9 @@ export declare function withRunnerVerbose(runner: RunnerValue, args: string[], v
89
44
  * A stock runner given the flag and a stdin pipe its parent never writes to
90
45
  * exits as soon as the pipe reaches end of file: when the parent dies. A
91
46
  * `custom` runner's argv is user-authored, so the flag is never spliced into
92
- * it, and it keeps an ignored stdin. Like {@link withRunnerVerbose} the flag
93
- * goes at index 2, after `[<bin>, <command>]`, and is a pure runtime toggle
94
- * applied just before spawn — never part of the task's `commandIr` or any
95
- * hash.
47
+ * it, and it keeps an ignored stdin. The flag goes at index 2, after
48
+ * `[<bin>, <command>]`, and is a pure runtime toggle applied just before
49
+ * spawn — never part of the task object or any hash.
96
50
  *
97
51
  * @param runner - the runner the argv was built for (gates the injection)
98
52
  * @param args - the fully-built argv
@@ -1 +1 @@
1
- {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/runner.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5F;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;EAKrB,CAAC;AACH,MAAM,MAAM,UAAU,GAAG,OAAO,UAAU,CAAC;AAE3C,MAAM,MAAM,WAAW,GAAG,WAAW,CAAC,OAAO,UAAU,CAAC,CAAC;AAMzD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,YAAY,CAAC,CAAC,EAAE,WAAW,EAAE,OAAO,GAAE,KAAK,GAAG,OAAe,GAAG,MAAM,EAAE,CASvF;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,EAAE,CAGlG;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,EAAE,CAGhF"}
1
+ {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../src/runner.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;GAMG;AAEH,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5F;;;;;;;;;;GAUG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;EAKrB,CAAC;AACH,MAAM,MAAM,UAAU,GAAG,OAAO,UAAU,CAAC;AAE3C,MAAM,MAAM,WAAW,GAAG,WAAW,CAAC,OAAO,UAAU,CAAC,CAAC;AAEzD;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,MAAM,EAAE,CAGhF"}
@@ -3,29 +3,23 @@
3
3
  * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
4
  */
5
5
  /**
6
- * Runner wire types for e3 functions.
6
+ * Runner wire types for e3 tasks, functions and records.
7
7
  *
8
- * `RunnerType` is the wire image of the SDK's `Runner` union (minus its
9
- * `custom` raw-argv runtime — see the security note below). It pins the
10
- * executable to a known runtime for every tag, so a function call can never
11
- * name its own executable; only platform flags vary.
12
- *
13
- * A `platforms` entry is just a `-p <name>` flag on the wire; the SDK's
14
- * `Platform<Known> | { custom }` distinction is authoring sugar that
15
- * collapses to a string.
8
+ * `RunnerType` is the wire image of the SDK's `Runner` union. A known-runtime
9
+ * tag pins the executable to one of the stock runners, which runs units through
10
+ * its `exec` command; `custom` names a command of the author's own.
16
11
  */
17
12
  import { VariantType, StructType, ArrayType, StringType } from '@elaraai/east';
18
13
  /**
19
- * Wire representation of a runner — shared by tasks and functions
20
- * (symmetric: both carry `runner: RunnerType`).
21
- *
22
- * The known-runtime tags name a runtime binary; `platforms` are passed as
23
- * `-p` flags. `custom` carries a raw argv prefix: for functions it is the
24
- * executed command (the standard `-i/-o/<ir>` suffix is appended, so the
25
- * command must speak the runner CLI convention); for tasks it is routing
26
- * metadata only — a task's `commandIr` remains authoritative for execution.
27
- * Package authors can already execute arbitrary commands via custom tasks,
28
- * so `custom` grants no capability that tasks don't have.
14
+ * Wire representation of a runner — shared by tasks, functions and records.
15
+ *
16
+ * A known-runtime tag names a stock runner, and `platforms` names the platform
17
+ * packages the units it runs load. `custom` carries a command, which e3 runs
18
+ * with the arguments of a stock runner's `run`: `-i` for each input, `-o` for
19
+ * the output, then the program's file. A custom task's body is its own
20
+ * command, and its runner's is empty. Package authors can already execute
21
+ * arbitrary commands via custom tasks, so `custom` grants no capability that
22
+ * tasks don't have.
29
23
  */
30
24
  export const RunnerType = VariantType({
31
25
  east_node: StructType({ platforms: ArrayType(StringType) }),
@@ -33,62 +27,6 @@ export const RunnerType = VariantType({
33
27
  east_c: StructType({ platforms: ArrayType(StringType) }),
34
28
  custom: StructType({ command: ArrayType(StringType) }),
35
29
  });
36
- function flags(platforms) {
37
- return platforms.flatMap((p) => ['-p', p]);
38
- }
39
- /**
40
- * Resolve a {@link RunnerType} value to the argv prefix of one of its
41
- * commands (the wire-value analogue of the SDK's `runnerToCommand`): `run`,
42
- * the default — `[<bin>, 'run', -p…]` — or `merge`, the blob merge every
43
- * stock runner ships — `[<bin>, 'merge', -p…]`, the fan-in of a partitioned
44
- * task's keyed partials (issue #770). Lives in e3-types so both e3-core
45
- * (local) and the cloud execution kernel import the one resolver.
46
- *
47
- * Variant tags use underscores (`east_node`) mapped to the binary name
48
- * (`east-node`) here. A `custom` runner's command is its `run`; it has no
49
- * merge command.
50
- *
51
- * @param r - the runner
52
- * @param command - the runner command, `run` by default
53
- * @returns the argv prefix
54
- * @throws {Error} When `merge` is asked of a custom runner.
55
- */
56
- export function runnerToArgv(r, command = 'run') {
57
- switch (r.type) {
58
- case 'east_node': return ['east-node', command, ...flags(r.value.platforms)];
59
- case 'east_py': return ['east-py', command, ...flags(r.value.platforms)];
60
- case 'east_c': return ['east-c', command, ...flags(r.value.platforms)];
61
- case 'custom':
62
- if (command !== 'run')
63
- throw new Error(`a custom runner has no ${command} command`);
64
- return [...r.value.command];
65
- }
66
- }
67
- /**
68
- * Insert the runner's `-v/--verbose` flag into a fully-built argv, for the
69
- * known runtimes only.
70
- *
71
- * All three known runners (`east-node`/`east-py`/`east-c`, `run` and `merge`)
72
- * accept `-v` among their options and print timing/perf detail to stderr; a
73
- * `custom` runner's argv is user-authored, so a flag is never spliced into
74
- * it. A known-runtime argv always starts `[<bin>, <command>, …]` (see
75
- * {@link runnerToArgv} and the SDK's `runnerToCommand`), so `-v` goes at
76
- * index 2 — ahead of the `-p`/`-i`/`-o` flags and the trailing IR path.
77
- *
78
- * This is a pure **runtime** toggle: it is applied to the *evaluated* argv
79
- * immediately before spawn and never touches the task's `commandIr`, the
80
- * {@link RunnerType}, or any hash — so it cannot affect caching.
81
- *
82
- * @param runner - the runner the argv was built for (gates the injection)
83
- * @param args - the fully-built argv (runner prefix + `-i`/`-o`/`<ir>` suffix)
84
- * @param verbose - when true, request the runner's verbose output
85
- * @returns the argv, with `-v` inserted for known runtimes when verbose
86
- */
87
- export function withRunnerVerbose(runner, args, verbose) {
88
- if (!verbose || runner.type === 'custom' || args.length < 2)
89
- return args;
90
- return [...args.slice(0, 2), '-v', ...args.slice(2)];
91
- }
92
30
  /**
93
31
  * Insert the runner's `--exit-with-parent` flag into a fully-built argv, for
94
32
  * the known runtimes only — the stdin lifeline (issue #770).
@@ -96,10 +34,9 @@ export function withRunnerVerbose(runner, args, verbose) {
96
34
  * A stock runner given the flag and a stdin pipe its parent never writes to
97
35
  * exits as soon as the pipe reaches end of file: when the parent dies. A
98
36
  * `custom` runner's argv is user-authored, so the flag is never spliced into
99
- * it, and it keeps an ignored stdin. Like {@link withRunnerVerbose} the flag
100
- * goes at index 2, after `[<bin>, <command>]`, and is a pure runtime toggle
101
- * applied just before spawn — never part of the task's `commandIr` or any
102
- * hash.
37
+ * it, and it keeps an ignored stdin. The flag goes at index 2, after
38
+ * `[<bin>, <command>]`, and is a pure runtime toggle applied just before
39
+ * spawn — never part of the task object or any hash.
103
40
  *
104
41
  * @param runner - the runner the argv was built for (gates the injection)
105
42
  * @param args - the fully-built argv
@@ -1 +1 @@
1
- {"version":3,"file":"runner.js","sourceRoot":"","sources":["../../src/runner.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,UAAU,EAAe,MAAM,eAAe,CAAC;AAE5F;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,WAAW,CAAC;IACpC,SAAS,EAAE,UAAU,CAAC,EAAE,SAAS,EAAE,SAAS,CAAC,UAAU,CAAC,EAAE,CAAC;IAC3D,OAAO,EAAI,UAAU,CAAC,EAAE,SAAS,EAAE,SAAS,CAAC,UAAU,CAAC,EAAE,CAAC;IAC3D,MAAM,EAAK,UAAU,CAAC,EAAE,SAAS,EAAE,SAAS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