@telorun/analyzer 0.60.0 → 0.62.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 (88) hide show
  1. package/dist/analyzer.d.ts.map +1 -1
  2. package/dist/analyzer.js +130 -9
  3. package/dist/artifact-layer-index.d.ts +13 -5
  4. package/dist/artifact-layer-index.d.ts.map +1 -1
  5. package/dist/artifact-layer-index.js +37 -13
  6. package/dist/artifact-selector.d.ts +10 -3
  7. package/dist/artifact-selector.d.ts.map +1 -1
  8. package/dist/artifact-selector.js +10 -1
  9. package/dist/builtins.d.ts.map +1 -1
  10. package/dist/builtins.js +97 -13
  11. package/dist/cel-bindings.d.ts +0 -6
  12. package/dist/cel-bindings.d.ts.map +1 -1
  13. package/dist/cel-bindings.js +3 -28
  14. package/dist/definition-registry.d.ts +17 -0
  15. package/dist/definition-registry.d.ts.map +1 -1
  16. package/dist/definition-registry.js +31 -2
  17. package/dist/identifier-name.d.ts +114 -0
  18. package/dist/identifier-name.d.ts.map +1 -0
  19. package/dist/identifier-name.js +183 -0
  20. package/dist/index.d.ts +14 -2
  21. package/dist/index.d.ts.map +1 -1
  22. package/dist/index.js +11 -2
  23. package/dist/manifest-schemas.d.ts +81 -0
  24. package/dist/manifest-schemas.d.ts.map +1 -1
  25. package/dist/manifest-schemas.js +208 -6
  26. package/dist/module-file-claims.d.ts +7 -0
  27. package/dist/module-file-claims.d.ts.map +1 -1
  28. package/dist/module-file-claims.js +22 -2
  29. package/dist/module-library.d.ts +97 -0
  30. package/dist/module-library.d.ts.map +1 -0
  31. package/dist/module-library.js +162 -0
  32. package/dist/requires-block.d.ts +125 -0
  33. package/dist/requires-block.d.ts.map +1 -0
  34. package/dist/requires-block.js +182 -0
  35. package/dist/schema-keywords.d.ts +68 -0
  36. package/dist/schema-keywords.d.ts.map +1 -0
  37. package/dist/schema-keywords.js +324 -0
  38. package/dist/schema-region.d.ts +12 -1
  39. package/dist/schema-region.d.ts.map +1 -1
  40. package/dist/schema-region.js +12 -1
  41. package/dist/telo-version.d.ts +3 -0
  42. package/dist/telo-version.d.ts.map +1 -0
  43. package/dist/telo-version.js +8 -0
  44. package/dist/types.d.ts +31 -0
  45. package/dist/types.d.ts.map +1 -1
  46. package/dist/validate-identifier-names.d.ts +31 -0
  47. package/dist/validate-identifier-names.d.ts.map +1 -0
  48. package/dist/validate-identifier-names.js +144 -0
  49. package/dist/validate-module-artifact.d.ts.map +1 -1
  50. package/dist/validate-module-artifact.js +53 -1
  51. package/dist/validate-observed-state.d.ts +9 -2
  52. package/dist/validate-observed-state.d.ts.map +1 -1
  53. package/dist/validate-observed-state.js +9 -2
  54. package/dist/validate-references.d.ts.map +1 -1
  55. package/dist/validate-references.js +5 -26
  56. package/dist/validate-requires.d.ts +49 -0
  57. package/dist/validate-requires.d.ts.map +1 -0
  58. package/dist/validate-requires.js +99 -0
  59. package/dist/value-type-keyword.d.ts +1 -1
  60. package/dist/value-type-keyword.d.ts.map +1 -1
  61. package/dist/value-type-keyword.js +1 -0
  62. package/dist/version-range.d.ts +88 -0
  63. package/dist/version-range.d.ts.map +1 -0
  64. package/dist/version-range.js +173 -0
  65. package/package.json +2 -2
  66. package/src/analyzer.ts +146 -10
  67. package/src/artifact-layer-index.ts +47 -14
  68. package/src/artifact-selector.ts +15 -4
  69. package/src/builtins.ts +102 -13
  70. package/src/cel-bindings.ts +3 -28
  71. package/src/definition-registry.ts +30 -2
  72. package/src/identifier-name.ts +228 -0
  73. package/src/index.ts +44 -1
  74. package/src/manifest-schemas.ts +223 -4
  75. package/src/module-file-claims.ts +32 -2
  76. package/src/module-library.ts +208 -0
  77. package/src/requires-block.ts +253 -0
  78. package/src/schema-keywords.ts +359 -0
  79. package/src/schema-region.ts +12 -1
  80. package/src/telo-version.ts +9 -0
  81. package/src/types.ts +32 -0
  82. package/src/validate-identifier-names.ts +173 -0
  83. package/src/validate-module-artifact.ts +56 -0
  84. package/src/validate-observed-state.ts +9 -2
  85. package/src/validate-references.ts +5 -26
  86. package/src/validate-requires.ts +129 -0
  87. package/src/value-type-keyword.ts +1 -0
  88. package/src/version-range.ts +238 -0
@@ -7,34 +7,9 @@ import { extractContextsFromSchema } from "./validate-cel-context.js";
7
7
  * contexts that see it may be anchored anywhere (a decision table annotates both
8
8
  * `choices` and `default`). */
9
9
  export const BINDINGS_ANNOTATION = "x-telo-bindings-from";
10
- /**
11
- * CEL keywords. A binding named after one is unreachable — `true` lexes as a
12
- * literal, `in` as an operator so it is reserved alongside the scope names,
13
- * which turns silence into a diagnostic.
14
- */
15
- export const CEL_RESERVED_WORDS = [
16
- "as",
17
- "break",
18
- "const",
19
- "continue",
20
- "else",
21
- "false",
22
- "for",
23
- "function",
24
- "if",
25
- "import",
26
- "in",
27
- "let",
28
- "loop",
29
- "namespace",
30
- "null",
31
- "package",
32
- "return",
33
- "true",
34
- "var",
35
- "void",
36
- "while",
37
- ];
10
+ // CEL keywords live in `identifier-name.ts` — a binding named after one is
11
+ // unreachable for exactly the reason a resource or step named after one is, so
12
+ // the list belongs to the identifier vocabulary rather than to this file.
38
13
  /** Locate a kind's bindings field and the scope names its annotated contexts
39
14
  * declare. Returns undefined for a kind that declares no bindings region. */
40
15
  export function findBindingSites(definitionSchema) {
@@ -52,6 +52,23 @@ export declare class DefinitionRegistry {
52
52
  * `$ref: "telo://<module>/<Name>"` would then silently validate against the
53
53
  * kind's schema instead. The caller reports it; nothing is overwritten. */
54
54
  registerNamedTypeSchema(id: string, schema: Record<string, any>): boolean;
55
+ /**
56
+ * Register a schema, surviving one AJV refuses.
57
+ *
58
+ * `addSchema` META-VALIDATES and THROWS, and a throw here escapes the whole
59
+ * analyze pass: one author schema with `minimum: "3"` in it aborted the run
60
+ * with AJV's own unanchored text and took every other diagnostic in the file
61
+ * down with it — including the anchored one that says exactly which keyword is
62
+ * wrong. Registration is a lookup table for `$ref` resolution, so failing to
63
+ * fill one entry costs a reference that could not have resolved anyway.
64
+ *
65
+ * Nothing is swallowed: an unregisterable schema is invalid, and the two
66
+ * checks that report it both run afterwards and both anchor on the offending
67
+ * line — `SCHEMA_VIOLATION` from the `KindSchema` / `JsonSchema7` fragment the
68
+ * slot points at, and `SCHEMA_COMPILE_ERROR` from {@link schemaCompileError},
69
+ * which wraps `compile` for this same reason.
70
+ */
71
+ private tryAddSchema;
55
72
  /** True when a schema is registered under `id` (a canonical `telo://` type id
56
73
  * or a definition `$id`). Used to flag schema `$ref`s that resolve to nothing. */
57
74
  hasSchemaId(id: string): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"definition-registry.d.ts","sourceRoot":"","sources":["../src/definition-registry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAEzE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEzD,OAAO,EAIL,KAAK,iBAAiB,EACvB,MAAM,0BAA0B,CAAC;AAIlC,+EAA+E;AAC/E,qBAAa,kBAAkB;;IAK7B;;sFAEkF;IAClF,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAe;IACnC,OAAO,CAAC,QAAQ,CAAC,mBAAmB,CAAqB;IACzD;;mFAE+E;IAC/E,OAAO,CAAC,QAAQ,CAAC,mBAAmB,CAAqB;IAEzD,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAyC;IAC9D,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAwC;IAClE,mEAAmE;IACnE,OAAO,CAAC,QAAQ,CAAC,UAAU,CAA+B;IAC1D;;;;wEAIoE;IACpE,OAAO,CAAC,QAAQ,CAAC,WAAW,CAA6B;IAEzD,QAAQ,CAAC,UAAU,EAAE,kBAAkB,GAAG,IAAI;IAoC9C,OAAO,CAAC,aAAa;IASrB;;;;;;;;;;;;;2FAauF;IACvF,sBAAsB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,EAAE,UAAU,EAAE,MAAM,GAAG,IAAI;IAK1E;;;;;;;;;;gFAU4E;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,EAAE,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,SAAS;IAMxD;;;;oFAIgF;IAChF,gBAAgB,CAAC,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,EAAE;IAWtE;;;;;;iCAM6B;IAC7B,kBAAkB,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,GAAG,SAAS;IASnE;;;;4EAIwE;IACxE,OAAO,CAAC,iBAAiB;IAqBzB;;;;;;;;;;;;;;4BAcwB;IACxB,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;IAShD,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,kBAAkB,GAAG,SAAS;IAIrD;;;uCAGmC;IACnC,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,iBAAiB,GAAG,SAAS;IAWxD,gGAAgG;IAChG,kBAAkB,CAChB,IAAI,EAAE,MAAM,EACZ,OAAO,CAAC,EAAE;QAAE,WAAW,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAA;KAAE,GACvD,iBAAiB,GAAG,SAAS;IAOhC;;;;;;;;qFAQiF;IACjF,2BAA2B,CACzB,QAAQ,EAAE,gBAAgB,EAC1B,OAAO,EAAE,aAAa,EACtB,eAAe,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,CAAC,GAC1C,iBAAiB,GAAG,SAAS;IAkChC,OAAO,CAAC,uBAAuB;IA+B/B;;qEAEiE;IACjE,YAAY,CAAC,YAAY,EAAE,MAAM,GAAG,kBAAkB,EAAE;IAgBxD,KAAK,IAAI,MAAM,EAAE;CAGlB"}
@@ -108,10 +108,36 @@ export class DefinitionRegistry {
108
108
  return false;
109
109
  if (this.registeredSchemaIds.has(id) || this.ajv.getSchema(id))
110
110
  return true;
111
- this.ajv.addSchema(schema, id);
111
+ if (!this.tryAddSchema(schema, id))
112
+ return true;
112
113
  this.registeredSchemaIds.add(id);
113
114
  return true;
114
115
  }
116
+ /**
117
+ * Register a schema, surviving one AJV refuses.
118
+ *
119
+ * `addSchema` META-VALIDATES and THROWS, and a throw here escapes the whole
120
+ * analyze pass: one author schema with `minimum: "3"` in it aborted the run
121
+ * with AJV's own unanchored text and took every other diagnostic in the file
122
+ * down with it — including the anchored one that says exactly which keyword is
123
+ * wrong. Registration is a lookup table for `$ref` resolution, so failing to
124
+ * fill one entry costs a reference that could not have resolved anyway.
125
+ *
126
+ * Nothing is swallowed: an unregisterable schema is invalid, and the two
127
+ * checks that report it both run afterwards and both anchor on the offending
128
+ * line — `SCHEMA_VIOLATION` from the `KindSchema` / `JsonSchema7` fragment the
129
+ * slot points at, and `SCHEMA_COMPILE_ERROR` from {@link schemaCompileError},
130
+ * which wraps `compile` for this same reason.
131
+ */
132
+ tryAddSchema(schema, id) {
133
+ try {
134
+ this.ajv.addSchema(schema, id);
135
+ return true;
136
+ }
137
+ catch {
138
+ return false;
139
+ }
140
+ }
115
141
  /** True when a schema is registered under `id` (a canonical `telo://` type id
116
142
  * or a definition `$id`). Used to flag schema `$ref`s that resolve to nothing. */
117
143
  hasSchemaId(id) {
@@ -173,7 +199,10 @@ export class DefinitionRegistry {
173
199
  if (this.ajv.getSchema(id)) {
174
200
  throw new Error(`Duplicate definition schema $id: "${id}" is already registered`);
175
201
  }
176
- this.ajv.addSchema(schema, id);
202
+ // A schema AJV refuses is left unregistered rather than aborting the pass —
203
+ // see {@link tryAddSchema}. The id stays claimed either way, so a later
204
+ // named type cannot quietly take a kind's place.
205
+ this.tryAddSchema(schema, id);
177
206
  this.registeredSchemaIds.add(id);
178
207
  this.definitionSchemaIds.add(id);
179
208
  }
@@ -0,0 +1,114 @@
1
+ /**
2
+ * Naming rules for every author-written Telo identifier — resource instances,
3
+ * kinds, modules, import aliases, step names, config declarations and CEL
4
+ * bindings. The single reader, so no surface re-derives the vocabulary; the
5
+ * `ref-slot.ts` / `zone-slot.ts` precedent.
6
+ *
7
+ * **The rules exist because Telo has no lexer.** A name is a YAML scalar, so
8
+ * nothing rejects its shape where it is declared, and every consequence
9
+ * surfaces later at a CEL site that references it — or not at all. Probed
10
+ * against the engine the runtime actually uses (`@marcbachmann/cel-js`):
11
+ *
12
+ * resources.my-server.url → EVALUATES, as `resources.my - server.url`
13
+ * resources.in → ParseError: Expected IDENTIFIER, got IN
14
+ * resources.2fa → ParseError
15
+ * resources.for → parses fine
16
+ *
17
+ * The first line is the one that decides the design. When a bare name is in
18
+ * scope — which `x-telo-bindings-from` deliberately makes possible — a
19
+ * hyphenated resource name yields a wrong number with no diagnostic anywhere.
20
+ * That is a swallowed error in the reference grammar, not a style preference.
21
+ * The last line is why the reserved set here is the whole keyword list rather
22
+ * than the subset today's parser happens to reject in field position: which
23
+ * keywords tokenize there is a property of a dependency, and a name that
24
+ * breaks on a parser upgrade was never safe.
25
+ *
26
+ * **Three tiers, because they fail in three different ways.**
27
+ *
28
+ * 1. `INVALID_NAME` (error, every surface) — not a CEL-safe identifier, or a
29
+ * CEL keyword. Below this line the name is unreferenceable or silently
30
+ * mis-referenced. This subsumes the old dot-only rule, which was the
31
+ * strictest special case of it: `!ref` splits on the first dot.
32
+ *
33
+ * 2. `INVALID_TYPE_NAME` (error) — a type-level name not starting uppercase.
34
+ * An error rather than a warning because half the reference grammar already
35
+ * rejects the alternative: `EXTENDS_ALIAS_PATTERN` in the kernel's manifest
36
+ * schema hard-rejects `extends: foo.Bar`, while nothing rejects the
37
+ * `metadata.name: foo` that produced it. A lowercase kind is a kind nobody
38
+ * can extend, so this only moves an existing failure to where it is
39
+ * fixable.
40
+ *
41
+ * 3. `NAME_CASE_CONVENTION` (warning) — a value-level name not starting
42
+ * lowercase. Warn-only, Rust's `non_snake_case` posture: a name is
43
+ * occasionally dictated from outside, and Telo has no `#[allow]`, so a hard
44
+ * error would leave no escape.
45
+ *
46
+ * **The convention: case encodes what the name denotes.** PascalCase names a
47
+ * *type* — something writable in `kind:` / `extends:` / an `x-telo-ref` or type
48
+ * slot. camelCase names a *value* — something holding data at runtime, read
49
+ * through `resources.` / `steps.` / `variables.` in CEL. That is what
50
+ * distinguishes `kind: Console.WriteLine` from `!ref Console.writeLine`, two
51
+ * character-identical grammars otherwise, and the collision is not
52
+ * hypothetical: it is the sanctioned singleton pattern (declare
53
+ * `kind: Self.WriteLine`, export the instance, withhold the kind).
54
+ *
55
+ * **Only the first character is checked.** A full camelCase pattern would
56
+ * relitigate `httpApi` vs `httpAPI` and `OAuthClient` vs `OauthClient` with no
57
+ * benefit — the first character is what carries the type/value signal, and a
58
+ * stricter rule would fight legitimate names containing acronyms or digits
59
+ * while owning a judgement nobody asked this pass to make. An
60
+ * entirely-acronym type name (`SQL`, `AI`) passes unchanged.
61
+ *
62
+ * **No `DiagnosticFix`.** A fix is a whole-value replacement for ONE node,
63
+ * and a rename is only correct when every reference moves with it — offering
64
+ * one here would rewrite `metadata.name` and break every `!ref` and CEL read
65
+ * of it. Renaming belongs to a refactor that owns the reference graph.
66
+ *
67
+ * Browser-safe: pure string predicates, no I/O, no Node built-ins.
68
+ */
69
+ import { DiagnosticSeverity } from "./types.js";
70
+ /**
71
+ * CEL keywords. A name matching one is unreachable — `true` lexes as a
72
+ * literal, `in` as an operator — so it is reserved everywhere a name becomes a
73
+ * CEL identifier, which is every surface this file governs.
74
+ */
75
+ export declare const CEL_RESERVED_WORDS: readonly string[];
76
+ /**
77
+ * Which half of the convention a name falls under.
78
+ *
79
+ * `type` — a name writable in a `kind:` / `extends:` / type slot: a module, a
80
+ * kind, an import alias, or a resource whose capability is `Telo.Type` (a
81
+ * named shape has no runtime instance, so its name denotes a type even though
82
+ * it is declared as a resource).
83
+ *
84
+ * `value` — a name read through a CEL scope: a resource instance, a step, a
85
+ * `variables` / `secrets` / `ports` declaration, a CEL binding.
86
+ */
87
+ export type NameLevel = "type" | "value";
88
+ /** Document kinds whose `metadata.name` is type-level. Everything else
89
+ * declaring a name is a resource instance, whose level is decided by its
90
+ * kind's capability (see {@link NameLevel}). */
91
+ export declare const TYPE_LEVEL_DOC_KINDS: ReadonlySet<string>;
92
+ export interface NameViolation {
93
+ /** Which tier failed. Callers use it to suppress a tier another check
94
+ * already reports better at that surface (the bindings site owns
95
+ * `reserved`, where it can also say what is being shadowed). */
96
+ tier: "grammar" | "reserved" | "case";
97
+ code: "INVALID_NAME" | "INVALID_TYPE_NAME" | "NAME_CASE_CONVENTION";
98
+ severity: DiagnosticSeverity;
99
+ /** Complete sentence(s), subject included — so every surface words the same
100
+ * rule the same way. */
101
+ message: string;
102
+ }
103
+ /**
104
+ * Check one author-written name.
105
+ *
106
+ * `surface` is the noun phrase naming what was declared ("resource name",
107
+ * "step name", "import alias"), used as the message's subject.
108
+ *
109
+ * Returns the first violation only: the tiers are ordered by how badly the
110
+ * name is broken, and telling an author their unparseable name is also
111
+ * miscased buries the part that matters.
112
+ */
113
+ export declare function checkName(name: string, level: NameLevel, surface: string): NameViolation | undefined;
114
+ //# sourceMappingURL=identifier-name.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"identifier-name.d.ts","sourceRoot":"","sources":["../src/identifier-name.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEhD;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,EAAE,SAAS,MAAM,EAsB/C,CAAC;AAQF;;;;;;;;;;GAUG;AACH,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC;AAEzC;;iDAEiD;AACjD,eAAO,MAAM,oBAAoB,EAAE,WAAW,CAAC,MAAM,CAMnD,CAAC;AAEH,MAAM,WAAW,aAAa;IAC5B;;qEAEiE;IACjE,IAAI,EAAE,SAAS,GAAG,UAAU,GAAG,MAAM,CAAC;IACtC,IAAI,EAAE,cAAc,GAAG,mBAAmB,GAAG,sBAAsB,CAAC;IACpE,QAAQ,EAAE,kBAAkB,CAAC;IAC7B;6BACyB;IACzB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;;;GASG;AACH,wBAAgB,SAAS,CACvB,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,SAAS,EAChB,OAAO,EAAE,MAAM,GACd,aAAa,GAAG,SAAS,CA6C3B"}
@@ -0,0 +1,183 @@
1
+ /**
2
+ * Naming rules for every author-written Telo identifier — resource instances,
3
+ * kinds, modules, import aliases, step names, config declarations and CEL
4
+ * bindings. The single reader, so no surface re-derives the vocabulary; the
5
+ * `ref-slot.ts` / `zone-slot.ts` precedent.
6
+ *
7
+ * **The rules exist because Telo has no lexer.** A name is a YAML scalar, so
8
+ * nothing rejects its shape where it is declared, and every consequence
9
+ * surfaces later at a CEL site that references it — or not at all. Probed
10
+ * against the engine the runtime actually uses (`@marcbachmann/cel-js`):
11
+ *
12
+ * resources.my-server.url → EVALUATES, as `resources.my - server.url`
13
+ * resources.in → ParseError: Expected IDENTIFIER, got IN
14
+ * resources.2fa → ParseError
15
+ * resources.for → parses fine
16
+ *
17
+ * The first line is the one that decides the design. When a bare name is in
18
+ * scope — which `x-telo-bindings-from` deliberately makes possible — a
19
+ * hyphenated resource name yields a wrong number with no diagnostic anywhere.
20
+ * That is a swallowed error in the reference grammar, not a style preference.
21
+ * The last line is why the reserved set here is the whole keyword list rather
22
+ * than the subset today's parser happens to reject in field position: which
23
+ * keywords tokenize there is a property of a dependency, and a name that
24
+ * breaks on a parser upgrade was never safe.
25
+ *
26
+ * **Three tiers, because they fail in three different ways.**
27
+ *
28
+ * 1. `INVALID_NAME` (error, every surface) — not a CEL-safe identifier, or a
29
+ * CEL keyword. Below this line the name is unreferenceable or silently
30
+ * mis-referenced. This subsumes the old dot-only rule, which was the
31
+ * strictest special case of it: `!ref` splits on the first dot.
32
+ *
33
+ * 2. `INVALID_TYPE_NAME` (error) — a type-level name not starting uppercase.
34
+ * An error rather than a warning because half the reference grammar already
35
+ * rejects the alternative: `EXTENDS_ALIAS_PATTERN` in the kernel's manifest
36
+ * schema hard-rejects `extends: foo.Bar`, while nothing rejects the
37
+ * `metadata.name: foo` that produced it. A lowercase kind is a kind nobody
38
+ * can extend, so this only moves an existing failure to where it is
39
+ * fixable.
40
+ *
41
+ * 3. `NAME_CASE_CONVENTION` (warning) — a value-level name not starting
42
+ * lowercase. Warn-only, Rust's `non_snake_case` posture: a name is
43
+ * occasionally dictated from outside, and Telo has no `#[allow]`, so a hard
44
+ * error would leave no escape.
45
+ *
46
+ * **The convention: case encodes what the name denotes.** PascalCase names a
47
+ * *type* — something writable in `kind:` / `extends:` / an `x-telo-ref` or type
48
+ * slot. camelCase names a *value* — something holding data at runtime, read
49
+ * through `resources.` / `steps.` / `variables.` in CEL. That is what
50
+ * distinguishes `kind: Console.WriteLine` from `!ref Console.writeLine`, two
51
+ * character-identical grammars otherwise, and the collision is not
52
+ * hypothetical: it is the sanctioned singleton pattern (declare
53
+ * `kind: Self.WriteLine`, export the instance, withhold the kind).
54
+ *
55
+ * **Only the first character is checked.** A full camelCase pattern would
56
+ * relitigate `httpApi` vs `httpAPI` and `OAuthClient` vs `OauthClient` with no
57
+ * benefit — the first character is what carries the type/value signal, and a
58
+ * stricter rule would fight legitimate names containing acronyms or digits
59
+ * while owning a judgement nobody asked this pass to make. An
60
+ * entirely-acronym type name (`SQL`, `AI`) passes unchanged.
61
+ *
62
+ * **No `DiagnosticFix`.** A fix is a whole-value replacement for ONE node,
63
+ * and a rename is only correct when every reference moves with it — offering
64
+ * one here would rewrite `metadata.name` and break every `!ref` and CEL read
65
+ * of it. Renaming belongs to a refactor that owns the reference graph.
66
+ *
67
+ * Browser-safe: pure string predicates, no I/O, no Node built-ins.
68
+ */
69
+ import { DiagnosticSeverity } from "./types.js";
70
+ /**
71
+ * CEL keywords. A name matching one is unreachable — `true` lexes as a
72
+ * literal, `in` as an operator — so it is reserved everywhere a name becomes a
73
+ * CEL identifier, which is every surface this file governs.
74
+ */
75
+ export const CEL_RESERVED_WORDS = [
76
+ "as",
77
+ "break",
78
+ "const",
79
+ "continue",
80
+ "else",
81
+ "false",
82
+ "for",
83
+ "function",
84
+ "if",
85
+ "import",
86
+ "in",
87
+ "let",
88
+ "loop",
89
+ "namespace",
90
+ "null",
91
+ "package",
92
+ "return",
93
+ "true",
94
+ "var",
95
+ "void",
96
+ "while",
97
+ ];
98
+ const RESERVED = new Set(CEL_RESERVED_WORDS);
99
+ /** What a CEL identifier may be — and therefore what a name that will be read
100
+ * through `resources.` / `steps.` / `variables.` must be. */
101
+ const CEL_IDENTIFIER_RE = /^[A-Za-z_][A-Za-z0-9_]*$/;
102
+ /** Document kinds whose `metadata.name` is type-level. Everything else
103
+ * declaring a name is a resource instance, whose level is decided by its
104
+ * kind's capability (see {@link NameLevel}). */
105
+ export const TYPE_LEVEL_DOC_KINDS = new Set([
106
+ "Telo.Application",
107
+ "Telo.Library",
108
+ "Telo.Definition",
109
+ "Telo.Abstract",
110
+ "Telo.Import",
111
+ ]);
112
+ /**
113
+ * Check one author-written name.
114
+ *
115
+ * `surface` is the noun phrase naming what was declared ("resource name",
116
+ * "step name", "import alias"), used as the message's subject.
117
+ *
118
+ * Returns the first violation only: the tiers are ordered by how badly the
119
+ * name is broken, and telling an author their unparseable name is also
120
+ * miscased buries the part that matters.
121
+ */
122
+ export function checkName(name, level, surface) {
123
+ const subject = `${surface} '${name}'`;
124
+ if (!CEL_IDENTIFIER_RE.test(name)) {
125
+ return {
126
+ tier: "grammar",
127
+ code: "INVALID_NAME",
128
+ severity: DiagnosticSeverity.Error,
129
+ message: `${subject} must match /^[A-Za-z_][A-Za-z0-9_]*$/ — ${grammarReason(name, level)}`,
130
+ };
131
+ }
132
+ if (RESERVED.has(name)) {
133
+ return {
134
+ tier: "reserved",
135
+ code: "INVALID_NAME",
136
+ severity: DiagnosticSeverity.Error,
137
+ message: `${subject} is a CEL keyword, so no expression can reference it. Rename it.`,
138
+ };
139
+ }
140
+ const first = name[0];
141
+ if (level === "type" && !(first >= "A" && first <= "Z")) {
142
+ return {
143
+ tier: "case",
144
+ code: "INVALID_TYPE_NAME",
145
+ severity: DiagnosticSeverity.Error,
146
+ message: `${subject} must start with an uppercase letter — it names a type, and the ` +
147
+ `alias-qualified grammar of 'kind:' / 'extends:' accepts only PascalCase.`,
148
+ };
149
+ }
150
+ if (level === "value" && !(first >= "a" && first <= "z")) {
151
+ return {
152
+ tier: "case",
153
+ code: "NAME_CASE_CONVENTION",
154
+ severity: DiagnosticSeverity.Warning,
155
+ message: `${subject} should start with a lowercase letter — camelCase names a value (read ` +
156
+ `through a CEL scope), PascalCase names a type.`,
157
+ };
158
+ }
159
+ return undefined;
160
+ }
161
+ /**
162
+ * Why the character set is what it is — which differs by level, and saying so
163
+ * accurately matters more than one shared sentence. A value-level name becomes
164
+ * a CEL identifier. A type-level name never does: it is a kind prefix or
165
+ * suffix, so what constrains it is the alias-qualified `<Alias>.<Kind>` grammar
166
+ * (`EXTENDS_ALIAS_PATTERN` in the kernel's manifest schema), which accepts the
167
+ * same characters for its own reasons.
168
+ */
169
+ function grammarReason(name, level) {
170
+ if (level === "type") {
171
+ return name.includes(".")
172
+ ? `a '.' separates the two halves of every '<Alias>.<Kind>' reference, so a dotted name cannot appear in either.`
173
+ : `that is the character set the alias-qualified '<Alias>.<Kind>' grammar accepts on both sides.`;
174
+ }
175
+ if (name.includes("-")) {
176
+ return (`it becomes a CEL identifier and CEL reads '-' as subtraction, so where a bare name is in ` +
177
+ `scope this evaluates as arithmetic instead of failing.`);
178
+ }
179
+ if (name.includes(".")) {
180
+ return `in a '!ref' the first '.' separates the import alias from the name.`;
181
+ }
182
+ return `it becomes a CEL identifier, so as written it cannot be referenced.`;
183
+ }
package/dist/index.d.ts CHANGED
@@ -7,6 +7,8 @@ export { collectZoneModuleDocuments, flattenForAnalyzer, flattenLoadedModule, fo
7
7
  export { buildEvalPaths, evalPathCovers } from "./eval-paths.js";
8
8
  export { BINDINGS_ANNOTATION, bindingContextProperties, bindingDependencies, findBindingSites, resolveBindingOrder, } from "./cel-bindings.js";
9
9
  export type { BindingSites } from "./cel-bindings.js";
10
+ export { CEL_RESERVED_WORDS, TYPE_LEVEL_DOC_KINDS, checkName, } from "./identifier-name.js";
11
+ export type { NameLevel, NameViolation } from "./identifier-name.js";
10
12
  export { applyObservedStateNode, buildObservedStateIndex, buildObservedStateResourcesSchema, collectRunReachableNames, observedStateRead, validateObservedStateDeclarations, OBSERVED_STATE_SCHEMA, } from "./validate-observed-state.js";
11
13
  export type { AnalyzedResource, ObservedStateRead } from "./validate-observed-state.js";
12
14
  export { moduleScopedDefResolver, scopeResolverForModule } from "./alias-resolver.js";
@@ -26,6 +28,13 @@ export type { RefSlot, RefUse, RefUseCases } from "./ref-slot.js";
26
28
  export { ANNOTATION_KEYWORDS, registerTeloKeywords, valueTypeKeyword, } from "./value-type-keyword.js";
27
29
  export { applyTextEdits, isPlainSafe, quoteStyleOf, renderFixReplacement, } from "./yaml-source-edit.js";
28
30
  export type { QuoteStyle, TextEdit } from "./yaml-source-edit.js";
31
+ export { KNOWN_HOST_AXES, evaluateRequires, readRequires } from "./requires-block.js";
32
+ export type { HostAxis, HostVersions, ReadRequiresResult, RequiresBlock, RequiresIssue, RequiresVerdict, } from "./requires-block.js";
33
+ export { TELO_SURFACE_VERSION } from "./telo-version.js";
34
+ export { validateRequires } from "./validate-requires.js";
35
+ export type { ValidateRequiresOptions } from "./validate-requires.js";
36
+ export { isUnsatisfiable, lowerBound, parseVersionRange, rangeAccepts, upperBound, } from "./version-range.js";
37
+ export type { ComparatorOperator, VersionComparator, VersionRange, VersionRangeResult, } from "./version-range.js";
29
38
  export { hasProvidesZone, hasRequiresZone, readProvidesZone, readRequiresZone, rewriteRequiresZoneKind, } from "./zone-slot.js";
30
39
  export type { ProvidesZoneSlot, RequiresZoneSlot } from "./zone-slot.js";
31
40
  export { deriveLibraryExportRequirements, projectZoneRequirements, runZoneAnalysis, zoneDocumentsSignature, } from "./resolve-zone-requirements.js";
@@ -70,11 +79,13 @@ export type { ParsedVersionedRef } from "./sources/versioned-ref.js";
70
79
  export { isLocalPathSource } from "./sources/local-path-ref.js";
71
80
  export { MANIFEST_CACHE_BASE_URL, ManifestCacheSource, isHttpsModuleRef, manifestCacheKey, manifestCacheUrl, ociManifestCacheCoords, urlManifestCacheCoords, } from "./sources/manifest-cache.js";
72
81
  export type { ManifestCacheCoords } from "./sources/manifest-cache.js";
73
- export { LAYER_ROLES, PLATFORM_AXES, ArtifactSelectorError, describeSelector, isLayerRole, normalizeSelector, selectorFromQualifiers, selectorKey, selectorMatches, } from "./artifact-selector.js";
82
+ export { CODE_LAYER_ROLES, LAYER_ROLES, PLATFORM_AXES, ArtifactSelectorError, describeSelector, isLayerRole, normalizeSelector, roleCarriesSelector, selectorFromQualifiers, selectorKey, selectorMatches, } from "./artifact-selector.js";
74
83
  export type { ArtifactSelector, LayerRole, PlatformAxis, PlatformTarget, } from "./artifact-selector.js";
75
84
  export { collectModuleFileClaims } from "./module-file-claims.js";
76
85
  export type { ModuleFileClaim } from "./module-file-claims.js";
77
- export { LayerIndexError, matchControllerLayers, parseLayerIndex, singletonLayer, } from "./artifact-layer-index.js";
86
+ export { readLibraryCandidates } from "./module-library.js";
87
+ export type { LibraryCandidate, LibraryCandidateProblem, LibraryCandidates, } from "./module-library.js";
88
+ export { LayerIndexError, codeLayerFor, matchCodeLayers, parseLayerIndex, singletonLayer, } from "./artifact-layer-index.js";
78
89
  export type { ArtifactLayer } from "./artifact-layer-index.js";
79
90
  export { validateModuleArtifact } from "./validate-module-artifact.js";
80
91
  export { PUBLISH_BLOCKING_CODES } from "./validate-module-metadata.js";
@@ -86,6 +97,7 @@ export type { CelNode, CelSegment } from "./cel-ast.js";
86
97
  export { DEFAULT_MANIFEST_FILENAME, DiagnosticSeverity, diagnosticFix } from "./types.js";
87
98
  export type { AnalysisDiagnostic, AnalysisOptions, DiagnosticData, DiagnosticFix, LoaderInitOptions, LoadOptions, ManifestSource, Position, PositionIndex, Range } from "./types.js";
88
99
  export * from "./manifest-schemas.js";
100
+ export * from "./schema-keywords.js";
89
101
  export { DERIVED_METADATA_FIELDS, authoredModuleMetadata, } from "./module-metadata-scope.js";
90
102
  export * from "./release/index.js";
91
103
  //# sourceMappingURL=index.d.ts.map
@@ -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,0BAA0B,EAC1B,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACxB,gBAAgB,EAChB,wBAAwB,EACxB,oBAAoB,EACpB,gCAAgC,EAChC,kBAAkB,EAClB,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,KAAK,YAAY,GACpB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjE,OAAO,EACL,mBAAmB,EACnB,wBAAwB,EACxB,mBAAmB,EACnB,gBAAgB,EAChB,mBAAmB,GACpB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EACL,sBAAsB,EACtB,uBAAuB,EACvB,iCAAiC,EACjC,wBAAwB,EACxB,iBAAiB,EACjB,iCAAiC,EACjC,qBAAqB,GACtB,MAAM,8BAA8B,CAAC;AACtC,YAAY,EAAE,gBAAgB,EAAE,i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EACvB,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AACpC,cAAc,oBAAoB,CAAC"}
package/dist/index.js CHANGED
@@ -4,6 +4,7 @@ export { importResolutionDiagnostics } from "./import-resolution-diagnostics.js"
4
4
  export { collectZoneModuleDocuments, flattenForAnalyzer, flattenLoadedModule, forwardReExportManifests, parseExportEntry, reExportSpecsFromExports, resolveExportedKinds, selectModuleManifestsForAnalysis, stampExportedKinds, stampReExportedKinds, } from "./flatten-for-analyzer.js";
5
5
  export { buildEvalPaths, evalPathCovers } from "./eval-paths.js";
6
6
  export { BINDINGS_ANNOTATION, bindingContextProperties, bindingDependencies, findBindingSites, resolveBindingOrder, } from "./cel-bindings.js";
7
+ export { CEL_RESERVED_WORDS, TYPE_LEVEL_DOC_KINDS, checkName, } from "./identifier-name.js";
7
8
  export { applyObservedStateNode, buildObservedStateIndex, buildObservedStateResourcesSchema, collectRunReachableNames, observedStateRead, validateObservedStateDeclarations, OBSERVED_STATE_SCHEMA, } from "./validate-observed-state.js";
8
9
  export { moduleScopedDefResolver, scopeResolverForModule } from "./alias-resolver.js";
9
10
  export { ancestorChain, contractDeclarer, controllerBearingAncestor, effectiveAuthorSchema, effectiveContractField, effectiveStatusSchema, hasOwnControllerOrTemplate, inheritedCapability, isInheritedDelegation, mappingFieldFor, needsContractMapping, resolveParent, } from "./extends-resolution.js";
@@ -14,6 +15,10 @@ export { buildReferenceFieldMap, isRefEntry, isScopeEntry } from "./reference-fi
14
15
  export { hasDeclaredUse, isRefSlot, isRefUse, possibleUses, readRefSlot, REF_USES, refSlotAnnotation, rewriteRefSlotKinds, transfersControl, } from "./ref-slot.js";
15
16
  export { ANNOTATION_KEYWORDS, registerTeloKeywords, valueTypeKeyword, } from "./value-type-keyword.js";
16
17
  export { applyTextEdits, isPlainSafe, quoteStyleOf, renderFixReplacement, } from "./yaml-source-edit.js";
18
+ export { KNOWN_HOST_AXES, evaluateRequires, readRequires } from "./requires-block.js";
19
+ export { TELO_SURFACE_VERSION } from "./telo-version.js";
20
+ export { validateRequires } from "./validate-requires.js";
21
+ export { isUnsatisfiable, lowerBound, parseVersionRange, rangeAccepts, upperBound, } from "./version-range.js";
17
22
  export { hasProvidesZone, hasRequiresZone, readProvidesZone, readRequiresZone, rewriteRequiresZoneKind, } from "./zone-slot.js";
18
23
  export { deriveLibraryExportRequirements, projectZoneRequirements, runZoneAnalysis, zoneDocumentsSignature, } from "./resolve-zone-requirements.js";
19
24
  export { validateZoneSlotDeclarations } from "./validate-zone-slots.js";
@@ -39,9 +44,10 @@ export { OCI_SCHEME, isOciRef, parseOciRef } from "./sources/oci-ref.js";
39
44
  export { parseVersionedRef, withRefVersion } from "./sources/versioned-ref.js";
40
45
  export { isLocalPathSource } from "./sources/local-path-ref.js";
41
46
  export { MANIFEST_CACHE_BASE_URL, ManifestCacheSource, isHttpsModuleRef, manifestCacheKey, manifestCacheUrl, ociManifestCacheCoords, urlManifestCacheCoords, } from "./sources/manifest-cache.js";
42
- export { LAYER_ROLES, PLATFORM_AXES, ArtifactSelectorError, describeSelector, isLayerRole, normalizeSelector, selectorFromQualifiers, selectorKey, selectorMatches, } from "./artifact-selector.js";
47
+ export { CODE_LAYER_ROLES, LAYER_ROLES, PLATFORM_AXES, ArtifactSelectorError, describeSelector, isLayerRole, normalizeSelector, roleCarriesSelector, selectorFromQualifiers, selectorKey, selectorMatches, } from "./artifact-selector.js";
43
48
  export { collectModuleFileClaims } from "./module-file-claims.js";
44
- export { LayerIndexError, matchControllerLayers, parseLayerIndex, singletonLayer, } from "./artifact-layer-index.js";
49
+ export { readLibraryCandidates } from "./module-library.js";
50
+ export { LayerIndexError, codeLayerFor, matchCodeLayers, parseLayerIndex, singletonLayer, } from "./artifact-layer-index.js";
45
51
  export { validateModuleArtifact } from "./validate-module-artifact.js";
46
52
  // Warnings everywhere, fatal at `telo publish` — descriptive metadata has no
47
53
  // runtime failure mode, so it must not stop a manifest running, but it is the
@@ -52,6 +58,9 @@ export { documentToAst, parseToAst } from "./yaml-ast.js";
52
58
  export { CelParseError, buildCelSegments, wrapCelAst } from "./cel-ast.js";
53
59
  export { DEFAULT_MANIFEST_FILENAME, DiagnosticSeverity, diagnosticFix } from "./types.js";
54
60
  export * from "./manifest-schemas.js";
61
+ // The JSON Schema vocabulary a manifest may write, as data — the source both the
62
+ // validating fragments and the IDE's completion are built from.
63
+ export * from "./schema-keywords.js";
55
64
  // The release model — module identity, fragments, the ledger, the edge graph and
56
65
  // version planning. Pure data in, plan out, so the editor and the CLI release
57
66
  // from one model.