@cratis/pi 7.48.0 → 7.48.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package/corpus/harnesses/copilot/instructions/local-work-artifacts.instructions.md +6 -2
- package/package/corpus/harnesses/copilot/instructions/profiles.instructions.md +1 -1
- package/package/corpus/hooks/README.md +11 -5
- package/package/corpus/hooks/scripts/cratis-cleanup-worktrees.sh +44 -4
- package/package/corpus/prompts/ship-changes.prompt.md +4 -1
- package/package/corpus/rules/local-work-artifacts.md +6 -2
- package/package/corpus/rules/profiles.md +1 -1
- package/package/corpus/skills/cratis-application-slice-conformance/SKILL.md +2 -2
- package/package/corpus/skills/cratis-chronicle-event-modeling/SKILL.md +1 -1
- package/package/corpus/skills/cratis-event-model-diagram/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/SKILL.md +4 -4
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/audit-format.md +1 -1
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/automation-patterns.md +3 -3
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/cases-to-specify.md +1 -1
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/public-events-and-direction.md +2 -2
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/todo-list-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/SKILL.md +6 -6
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/invocation-identity.md +3 -3
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/product-sources.md +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/specifying-triggers-and-clock.md +1 -1
- package/package/corpus/skills/cratis-screenplay-command-surface/SKILL.md +3 -3
- package/package/corpus/skills/cratis-screenplay-command-surface/references/compliance.md +1 -1
- package/package/corpus/skills/cratis-screenplay-command-surface/references/context.md +1 -1
- package/package/corpus/skills/cratis-screenplay-command-surface/references/enum-numbers.md +1 -1
- package/package/corpus/skills/cratis-screenplay-delivery-planning/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-delivery-planning/references/slice-counting.md +1 -1
- package/package/corpus/skills/cratis-screenplay-discovery/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-event-modeling/SKILL.md +3 -3
- package/package/corpus/skills/cratis-screenplay-event-modeling/references/parsed-not-runnable.md +2 -2
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/chronicle-observations.md +1 -1
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generate-notes.md +4 -5
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generated-recovery.md +1 -1
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/prologue-safety.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-authoring/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/language-reference.md +4 -4
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-tools.md +3 -3
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/model-notes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/screen-authoring-workflow.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-review/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/stop-or-assume.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-projections/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-read-surface/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-read-surface/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/SKILL.md +3 -3
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/drift-and-ledger.md +1 -1
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/gap-fill-handoff.md +2 -2
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/renderability-gate.md +2 -2
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/SKILL.md +2 -2
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-catalogue.md +1 -1
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/spec-forms-by-mode.md +5 -5
- package/package/corpus/skills/cratis-screenplay-slice-design/SKILL.md +2 -2
- package/package/corpus/skills/cratis-screenplay-slice-design/references/worked-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-specifications/SKILL.md +3 -3
- package/package/corpus/skills/cratis-screenplay-specifications/references/examples-and-routes.md +2 -2
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/SKILL.md +4 -4
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/boundaries.md +1 -1
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/chronicle-boundaries.md +1 -1
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/consistency-and-concurrency.md +2 -2
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution.md +1 -1
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/stream-patterns.md +2 -2
- package/package/corpus/skills/cratis-screenplay-toolchain/SKILL.md +42 -61
- package/package/corpus/skills/cratis-screenplay-toolchain/references/automation-translate-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet-example.md +7 -9
- package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet.md +15 -18
- package/package/corpus/skills/cratis-screenplay-toolchain/references/diagnostics.md +33 -53
- package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-subset.md +82 -93
- package/package/corpus/skills/cratis-screenplay-toolchain/references/generated-responses-example.md +4 -5
- package/package/corpus/skills/cratis-screenplay-toolchain/references/generation-strategies-example.md +1 -2
- package/package/corpus/skills/cratis-screenplay-toolchain/references/preferred-syntax.md +5 -9
- package/package/corpus/skills/cratis-screenplay-toolchain/references/production-routes-and-filters.md +7 -16
- package/package/corpus/skills/cratis-screenplay-toolchain/references/renderable-subset.md +38 -92
- package/package/corpus/skills/cratis-screenplay-toolchain/references/screenplay-contract-exceptions.json +4 -11
- package/package/corpus/skills/cratis-screenplay-toolchain/references/sources-and-streams.md +14 -19
- package/package/corpus/skills/cratis-screenplay-toolchain/references/traps.md +32 -35
- package/package/corpus/skills/cratis-screenplay-toolchain/references/verdicts.md +119 -52
- package/package/corpus/skills/cratis-screenplay-toolchain/verification.json +18 -24
- package/package/corpus/skills/cratis-screenplay-ui-composition/SKILL.md +3 -3
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/screen-composition-contract.md +2 -2
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/SKILL.md +110 -167
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/admission.md +74 -170
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/case-tables-and-whole-numbers.md +15 -35
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/choosing-generation.md +4 -6
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/render-example.md +23 -27
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/rendered-application.md +21 -33
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/sandbox-and-specrunner.md +61 -92
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/scene-runtime.md +4 -12
- package/package/corpus/skills/cratis-stage-rendering-and-sandbox/verification.json +10 -14
- package/package.json +1 -1
- package/package/corpus/skills/cratis-screenplay-toolchain/references/doc-contradictions.md +0 -72
- package/package/corpus/skills/cratis-screenplay-toolchain/references/provenance.md +0 -81
- package/package/corpus/skills/cratis-screenplay-toolchain/references/versions.md +0 -341
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: cratis-screenplay-toolchain
|
|
3
|
-
description: "
|
|
3
|
+
description: "How to run and check Cratis Screenplay `.play` models: locating the model, choosing the standalone `screenplay` tool or the `cratis` CLI, the exact command behind each verdict V1 to V5 and what a pass looks like, the executable and renderable subsets, reading PLAY, STAGE and CLI-RENDER diagnostics, traps, and a compiled cheat-sheet. Use when choosing a compiler, running or reading a verdict, fixing a diagnostic, or deciding whether syntax binds or renders. Not for: what to model or the phase workflow (use `cratis-screenplay-modeling-lifecycle`), the MCP editing loop (use `cratis-screenplay-model-authoring`), rendering workflow (use `cratis-screenplay-render-and-gap-fill`)."
|
|
4
4
|
license: MIT
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -20,20 +20,15 @@ skill answers "does it compile, bind, render, and which compiler said so". The m
|
|
|
20
20
|
Look first in the model root: the folder holding the project's `.play` files (else `Source/` or `src/`, else `Screenplay/`), or the root the project set with `mcpServers.screenplay.root` in `.cratis/ai.json`. A folder of `.play`
|
|
21
21
|
files is one application: always check the folder, never one file of it.
|
|
22
22
|
|
|
23
|
-
##
|
|
23
|
+
## Tool versions and the contract
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
Read the installed versions first: `screenplay --version`, `cratis --version`, and `which -a cratis`
|
|
26
|
+
(an older copy earlier on `PATH` shadows a newer install). The standalone tool and the compiler
|
|
27
|
+
bundled in the CLI are different releases, and the bundled one can be older; a construct the
|
|
28
|
+
standalone tool binds may be refused or unrendered through the CLI. Capabilities that need a
|
|
29
|
+
minimum release carry a one-line `Requires ...` note in the reference that teaches them.
|
|
26
30
|
|
|
27
|
-
|
|
28
|
-
CLI and bundled package pins: `references/versions.md`. The single version table records
|
|
29
|
-
released source evidence and historical probes separately; do not relabel an old
|
|
30
|
-
render/browser result as a probe of the current packages.
|
|
31
|
-
|
|
32
|
-
Historical screens-release evidence: CLI 3.40.7 / Stage 4.51.1 / bundled
|
|
33
|
-
Screenplay 4.114.0 opened the canonical corpus with `executableReady true`
|
|
34
|
-
and the stdio transcript exposed 37 tools; standalone language 4.122.0 was
|
|
35
|
-
recorded in that vector. These retained results are not a rerun on CLI 3.53.1
|
|
36
|
-
or the current standalone pin.
|
|
31
|
+
For exact diagnostic codes, MCP names/parameters and standalone CLI options, search the large published [references/screenplay-contract.json](references/screenplay-contract.json), named by [references/screenplay-contract.version](references/screenplay-contract.version), rather than loading it in full. Locate a diagnostic by its exact `code` (for example `"code": "PLAY0029"`), a tool by its exact `name` (for example `"name": "read-workspace"`), or a command in `cliCommands`; read the matched object for retirement, parameters or options. [references/screenplay-contract-exceptions.json](references/screenplay-contract-exceptions.json) records reasoned exceptions for superseded statements; it does not change the current contract.
|
|
37
32
|
|
|
38
33
|
## Ground rules
|
|
39
34
|
|
|
@@ -44,12 +39,11 @@ or the current standalone pin.
|
|
|
44
39
|
`cratis screenplay validate <folder> --warnings-as-errors`. Warnings hide defects:
|
|
45
40
|
PLAY0029 (a misspelt keyword or a `type` inside a slice) drops a construct silently.
|
|
46
41
|
3. **Pick the compiler deliberately and name it.** Standalone `screenplay` for
|
|
47
|
-
|
|
48
|
-
and generation.
|
|
49
|
-
|
|
50
|
-
version, rather than transferring a verdict across releases.
|
|
42
|
+
language checks and reference specifications; `cratis` for rendering
|
|
43
|
+
and generation. Report both tool and version, rather than transferring a verdict across
|
|
44
|
+
releases.
|
|
51
45
|
4. **Know the mode** (design, executable, renderable) and write from its subset.
|
|
52
|
-
5. **Capability is not correctness.** The tool you ran decides what is accepted
|
|
46
|
+
5. **Capability is not correctness.** The tool you ran decides what is accepted; the
|
|
53
47
|
domain and the documented semantics decide what is correct. On conflict keep the correct
|
|
54
48
|
model and record a tool gap; never reshape a model to silence a tool.
|
|
55
49
|
6. **Never remove `pii`, `secret`, authorization, list queries, automations or rules
|
|
@@ -70,9 +64,11 @@ or the current standalone pin.
|
|
|
70
64
|
| Scope/checks | `--scope <address>`, `--check <names>`; a scoped pass is not whole-application success | `validate --executable` (bundled binder, no write), `--check <names>`, `--scope`; `render --scope`/`--check`; `cratis screenplay conform` |
|
|
71
65
|
| Reference execution | `screenplay test <root>` or MCP `run-specifications` | Discover bundled MCP capability; target tests are not V4 |
|
|
72
66
|
| MCP | `screenplay mcp <root>`; discover schemas | `cratis screenplay mcp [root]`; registered by `cratis ai install` |
|
|
73
|
-
| Render
|
|
67
|
+
| Render boundary | Binder admission is not Stage admission | The CLI renders only ESM versions it knows; a newer bound model gets `CLI-RENDER-004` |
|
|
68
|
+
|
|
69
|
+
Read `references/verdicts.md` for exact commands, exit codes, the MCP roots caveat and the model notes gate.
|
|
74
70
|
|
|
75
|
-
|
|
71
|
+
Requires Cratis CLI 3.57.0 or later (`cratis --version`) to render models that use equality filters or concept generation strategies (ESM v14 and v15); an older CLI answers `CLI-RENDER-004`.
|
|
76
72
|
|
|
77
73
|
MCP calls below use the `screenplay` server declared in `.cratis/ai/mcp-servers.json`, for example `screenplay` → `read-workspace`.
|
|
78
74
|
|
|
@@ -89,10 +85,9 @@ Independent results, not a ladder. Read `references/verdicts.md` for the command
|
|
|
89
85
|
| V5 | rendered and target-verified | `cratis render`, then Debug build and tests; report admission, publication, build and tests separately |
|
|
90
86
|
|
|
91
87
|
V2 and V3 need MCP (V3 alone can also be read from `cratis screenplay validate --executable <root>`, labeled as the bundled compiler): send `initialize`, then `notifications/initialized`, and start the
|
|
92
|
-
server with a fixed root
|
|
93
|
-
4.60.1 bundled by cratis before 3.28.2; 4.66.0 and later and cratis 3.28.2 are fine). A subagent without MCP reports "V2 not run: no MCP in this agent".
|
|
88
|
+
server with a fixed root. A subagent without MCP reports "V2 not run: no MCP in this agent".
|
|
94
89
|
|
|
95
|
-
One line per verdict, tool first, for example `V1 pass (screenplay
|
|
90
|
+
One line per verdict, tool first, for example `V1 pass (screenplay <version>, 3 files)` and
|
|
96
91
|
`V3 blocked: PLAY0268 x3 (context filter, enum compliance)`. Name the source identity (commit plus the digest from
|
|
97
92
|
the source-identity helper (`cratis-screenplay-modeling-lifecycle` `references/verdicts-and-modes.md` "Source identity")) the verdict ran on; keep it apart from the MCP
|
|
98
93
|
`modelRevision`, which is semantic and, without `.screenplay/identities.json`,
|
|
@@ -103,46 +98,36 @@ changes with the root folder name.
|
|
|
103
98
|
- **Design**: every construct family parses; use it to model first. Compiled shapes:
|
|
104
99
|
`references/cheat-sheet.md`. Read [references/cheat-sheet-example.md](references/cheat-sheet-example.md) when you need one complete design-mode document with every construct family.
|
|
105
100
|
- **Executable** (binds, V3): `references/executable-subset.md`. Optional keyed lookups, unfiltered
|
|
106
|
-
lists and lists narrowed by one `by` key (observable too); caller-supplied equality
|
|
107
|
-
filters on collections bind as v14
|
|
101
|
+
lists and lists narrowed by one `by` key (observable too) bind; caller-supplied equality
|
|
102
|
+
filters on collections bind as ESM v14. Context `from`, single-result
|
|
108
103
|
filters, opaque `scoped to`/`performer` and composite `by` remain PLAY0268. Read
|
|
109
104
|
read-surface [equality filters](../cratis-screenplay-read-surface/references/equality-filters.md). No handler (PLAY0268, with or without `implementation`/`hint`); `reads` and
|
|
110
|
-
`concurrency` do not bind (PLAY0271); concept compliance binds as v13
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
from Screenplay 4.68.0 (also in the current CLI bundle) (`references/generated-responses-example.md`). Read [references/executable-example.md](references/executable-example.md) when you need a small StateChange and StateView model that binds executable, [references/pdl-example.md](references/pdl-example.md) when writing projection forms that bind and run, and [references/automation-translate-example.md](references/automation-translate-example.md) when writing Automation and Translate slices (ESM v6).
|
|
115
|
-
- **Renderable** (V5): `references/renderable-subset.md` has the current Stage 4.89.1 table and
|
|
116
|
-
explicitly labeled older probes. CLI 3.57.0 admits through v15; supported UUID/String
|
|
105
|
+
`concurrency` do not bind (PLAY0271); concept compliance binds as v13 (precise refusals: command-surface `references/compliance.md`);
|
|
106
|
+
generated values and `returns` responses bind (ESM v7, `references/generated-responses-example.md`). Read [references/executable-example.md](references/executable-example.md) when you need a small StateChange and StateView model that binds executable, [references/pdl-example.md](references/pdl-example.md) when writing projection forms that bind and run, and [references/automation-translate-example.md](references/automation-translate-example.md) when writing Automation and Translate slices (ESM v6).
|
|
107
|
+
- **Renderable** (V5): `references/renderable-subset.md` has the admission table. The CLI admits through
|
|
108
|
+
its newest known ESM version to construct checks; supported UUID/String
|
|
117
109
|
generation/responses, enum numbers, compliance, equality filters and event reactions render.
|
|
118
110
|
Unsupported generated types still get `STAGE-ESM-028`; result combinations get `-038`.
|
|
119
111
|
Newer versions refuse `CLI-RENDER-004`. Run admission
|
|
120
112
|
before claiming a particular model renders (`cratis render --scope` for an admitted part, `--check`
|
|
121
113
|
for no-write planning).
|
|
122
|
-
- **Event sources, streams and routes** bind as ESM v8
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
qualifying retained non-route Double literals select v11 at 4.135.0.
|
|
129
|
-
Composite view keys remain authoring-only (PLAY0268, #599), while one explicit
|
|
114
|
+
- **Event sources, streams and routes** bind as ESM v8. Operations and exact numeric source mode remain
|
|
115
|
+
unadmitted. Details: `references/sources-and-streams.md`.
|
|
116
|
+
- **Public contracts and routes (v9/v10/v11):** public contracts and direction select v9;
|
|
117
|
+
reaction identity, production overrides and observer filters select v10;
|
|
118
|
+
qualifying retained non-route Double literals select v11.
|
|
119
|
+
Composite view keys remain authoring-only (PLAY0268), while one explicit
|
|
130
120
|
`key` binds. Read `references/production-routes-and-filters.md` and read-surface
|
|
131
|
-
`references/named-keys.md
|
|
132
|
-
|
|
133
|
-
- **Published v12 (4.139.0):** non-positional enum numbers bind; canonical
|
|
121
|
+
`references/named-keys.md`.
|
|
122
|
+
- **Enum numbers (v12):** non-positional enum numbers bind; canonical
|
|
134
123
|
`numbers` parallels `values`. Positional pins preserve earlier executable
|
|
135
|
-
bytes/version. Specifications still use names.
|
|
136
|
-
non-positional numbers, and Stage 4.89.1 admits v12 and emits `Member = N`. Syntax:
|
|
124
|
+
bytes/version. Specifications still use names. Stage admits v12 and emits `Member = N`. Syntax:
|
|
137
125
|
command-surface `references/enum-numbers.md`; errors PLAY0667–0670 and opt-in
|
|
138
126
|
`enum-pinning` hint PLAY0671: `references/diagnostics.md`.
|
|
139
|
-
|
|
140
|
-
- **Published v15 (4.147.0):** concept strategies and Guarded freshness; strict fixture shapes,
|
|
127
|
+
- **Concept strategies (v15):** concept strategies and Guarded freshness; strict fixture shapes,
|
|
141
128
|
no silent retry. Read [references/generation-strategies-example.md](references/generation-strategies-example.md)
|
|
142
129
|
and command-surface `references/generated-values-and-responses.md` for supported strategies/refusals.
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
- **Caller/compliance metadata** at 4.127.0: `$identity` aliases caller built-ins;
|
|
130
|
+
- **Caller/compliance metadata:** `$identity` aliases caller built-ins;
|
|
146
131
|
additional identity details are metadata and executable reads still refuse.
|
|
147
132
|
Bare `pii`/`secret` replace legacy spellings; `pii personal` repeats one marker
|
|
148
133
|
(PLAY0653). Purposes/checks/processing records and event `subject` are report-only,
|
|
@@ -173,14 +158,14 @@ changes with the root folder name.
|
|
|
173
158
|
|
|
174
159
|
## Top traps
|
|
175
160
|
|
|
176
|
-
All 44, with fixes: `references/traps.md`. Read `references/traps.md` when diagnosing an unexpected compile, binding, rendering or MCP result.
|
|
161
|
+
All 44 traps, with fixes: `references/traps.md`. Read `references/traps.md` when diagnosing an unexpected compile, binding, rendering or MCP result.
|
|
177
162
|
|
|
178
|
-
Read [references/diagnostics.md](references/diagnostics.md) when a PLAY, STAGE or CLI-RENDER diagnostic needs its meaning and fix.
|
|
163
|
+
Read [references/diagnostics.md](references/diagnostics.md) when a PLAY, STAGE or CLI-RENDER diagnostic needs its meaning and fix. When the Screenplay documentation and the compiler disagree, follow the compiler for what is accepted, keep the intended semantics in the model, and record the gap.
|
|
179
164
|
|
|
180
165
|
1. Clean V1 is not executable: only MCP (V2) or `render` binds.
|
|
181
166
|
2. Prefer inline `produces event` for a command-owned event; plain command productions need explicit `for <identifier>`.
|
|
182
167
|
3. PLAY0029 is a warning: validate with warnings as errors.
|
|
183
|
-
4. Validate the folder; name the compiler
|
|
168
|
+
4. Validate the folder; name the compiler.
|
|
184
169
|
5. V1 warns on undeclared projection targets (`PLAY0514`) and removal/capture
|
|
185
170
|
event references (`PLAY0166`). Unmapped declared fields can be reported by
|
|
186
171
|
opt-in `--check field-origins` (`PLAY0534`); unknown coverage is skipped, so
|
|
@@ -190,7 +175,7 @@ Read [references/diagnostics.md](references/diagnostics.md) when a PLAY, STAGE o
|
|
|
190
175
|
7. Mark read-model identity with trailing `key`, not `identifier`. Otherwise single-instance
|
|
191
176
|
queries must agree on `by`; only with none and an admitted list query can `*Id`
|
|
192
177
|
inference run. Queryless views need `key` (read-surface `references/named-keys.md`).
|
|
193
|
-
Align projection keys. Multipart keys remain PLAY0268
|
|
178
|
+
Align projection keys. Multipart keys remain PLAY0268.
|
|
194
179
|
8. Projection `key` routes only on `from`; joins never create; `all` is per source.
|
|
195
180
|
9. `null` only for optional read-model properties in specifications.
|
|
196
181
|
10. `then` events are exhaustive and ordered; after `when append` they list only what followed.
|
|
@@ -216,9 +201,9 @@ reason; blocked verdicts list codes and keep the protection they blocked on.
|
|
|
216
201
|
- [ ] Any new example fence compiles with the standalone tool; unmarked fences also pass
|
|
217
202
|
`cratis screenplay validate --warnings-as-errors`.
|
|
218
203
|
|
|
219
|
-
Read [model notes gate](references/
|
|
220
|
-
unresolved questions: standalone
|
|
221
|
-
|
|
204
|
+
Read [model notes gate](references/verdicts.md#model-notes-gate) when checking
|
|
205
|
+
unresolved questions: the standalone tool has `--open-questions fail`; `cratis screenplay validate`
|
|
206
|
+
does not. It is separate from compilation and `--warnaserror`.
|
|
222
207
|
|
|
223
208
|
## Route near misses
|
|
224
209
|
|
|
@@ -230,7 +215,3 @@ unresolved questions: standalone 4.144.0 has `--open-questions fail`; Cratis CLI
|
|
|
230
215
|
- Rendering and gap-fill: `cratis-screenplay-render-and-gap-fill`,
|
|
231
216
|
`cratis-stage-rendering-and-sandbox`.
|
|
232
217
|
- Running systems (Chronicle server operations through the `cratis` CLI, with its authorization boundaries): `cratis-chronicle-cli-operations`.
|
|
233
|
-
|
|
234
|
-
## Lineage
|
|
235
|
-
|
|
236
|
-
Read `references/provenance.md` when checking attribution or the sources behind this guidance.
|
package/package/corpus/skills/cratis-screenplay-toolchain/references/automation-translate-example.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Automation and Translate example (ESM v6)
|
|
2
2
|
|
|
3
|
-
Executable Automation and Translate slices. Binds
|
|
3
|
+
Executable Automation and Translate slices. Binds as `executableReady` on the standalone tool and on the compiler bundled in the CLI; see [executable-subset.md](executable-subset.md) for what renders. Shows a reaction `produces` cascade, `invokes`, `where`, clock `at`, an application trigger, a capture with translate and a transition `when`, and v6 specifications.
|
|
4
4
|
|
|
5
5
|
The `Renew` command is ungated so that the reaction can invoke it: this is a syntax demonstration, not a safe production design. Reactions invoke with no caller, so a real model needs a trusted path (see [cratis-screenplay-automations-and-translations](../../cratis-screenplay-automations-and-translations/SKILL.md)).
|
|
6
6
|
|
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
# Cheat-sheet example (design mode)
|
|
2
2
|
|
|
3
|
-
One complete document with every construct family. Design mode, not executable. Prose rules: [cheat-sheet.md](cheat-sheet.md);
|
|
3
|
+
One complete document with every construct family. Design mode, not executable. Prose rules: [cheat-sheet.md](cheat-sheet.md); what binds: [executable-subset.md](executable-subset.md).
|
|
4
4
|
|
|
5
|
-
Binding blockers: unquoted import, `reads` (PLAY0271), `starts with`. Caller-supplied collection equality filters bind as ESM v14
|
|
5
|
+
Binding blockers: unquoted import, `reads` (PLAY0271), `starts with`. Caller-supplied collection equality filters bind as ESM v14; context and single-result filters remain blocked. Executable shapes are in the sibling examples. `RecordingAPayment` lists the `InvoiceClosed` cascade; an older bundled compiler rejected it with a false PLAY0285 ("outcome cannot be produced by 'RecordPayment'").
|
|
6
6
|
|
|
7
|
-
Concept compliance itself binds as ESM v13
|
|
8
|
-
|
|
9
|
-
4.147.1 / Stage 4.89.1 and renders v13 concept protection. Binder-only PLAY0268
|
|
10
|
-
refusals and subject-lineage limits: command-surface `references/compliance.md`.
|
|
7
|
+
Concept compliance itself binds as ESM v13; reasons remain report-only PLAY0270. Stage renders v13 concept
|
|
8
|
+
protection. Binder-only PLAY0268 refusals and subject-lineage limits: command-surface `references/compliance.md`.
|
|
11
9
|
|
|
12
10
|
```screenplay test=unbound
|
|
13
11
|
// Design-mode cheat-sheet: every construct family; compiles warning-free on the standalone tool.
|
|
@@ -17,7 +15,7 @@ import Customers.CustomerRegistered // unquoted = another bounded context
|
|
|
17
15
|
|
|
18
16
|
concept InvoiceId : Uuid // primitives: Uuid String Int Decimal Bool Date DateTime Enum
|
|
19
17
|
concept PaymentId : Uuid
|
|
20
|
-
concept Email : String pii //
|
|
18
|
+
concept Email : String pii // concept compliance binds as ESM v13
|
|
21
19
|
pii reason "Identifies a person"
|
|
22
20
|
validate
|
|
23
21
|
not empty message "An email is required"
|
|
@@ -158,7 +156,7 @@ module Billing
|
|
|
158
156
|
number String
|
|
159
157
|
query InvoiceById => InvoiceRow optional // keyed optional lookup (unfiltered lists bind too)
|
|
160
158
|
by invoiceId InvoiceId
|
|
161
|
-
query ListInvoices => observable InvoiceRow[] // caller-supplied equality filter: ESM v14
|
|
159
|
+
query ListInvoices => observable InvoiceRow[] // caller-supplied equality filter: ESM v14
|
|
162
160
|
filter number String optional
|
|
163
161
|
projection InvoiceList => InvoiceRow
|
|
164
162
|
from InvoiceRegistered
|
|
@@ -248,7 +246,7 @@ module Housekeeping // no gates: this reaction
|
|
|
248
246
|
produces event InvoiceMarkedOverdue
|
|
249
247
|
overdueAt DateTime = $context.occurred
|
|
250
248
|
// No command spec here: under ESM v6 it must list the ReminderSent cascade. The file is
|
|
251
|
-
// RecordingAPayment's cascade
|
|
249
|
+
// RecordingAPayment's cascade: an older bundled compiler reported a false PLAY0285 here.
|
|
252
250
|
// The cascade form: automation-translate-example.md (SubscribingAMember).
|
|
253
251
|
|
|
254
252
|
slice Automation RemindOverdue
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Screenplay cheat-sheet
|
|
1
|
+
# Screenplay cheat-sheet
|
|
2
2
|
|
|
3
3
|
## Contents
|
|
4
4
|
|
|
@@ -17,17 +17,15 @@ Released boundary forms: `public event X`, `event X from "store"`, Translate
|
|
|
17
17
|
and capture `source events` with `from ForeignEvent` select v9. Read
|
|
18
18
|
[public contracts](../../cratis-screenplay-automations-and-translations/references/public-events-and-direction.md).
|
|
19
19
|
View properties use trailing `key`; multipart `by` query/read blocks remain
|
|
20
|
-
PLAY0268
|
|
20
|
+
PLAY0268, not v10. Read [named keys](../../cratis-screenplay-read-surface/references/named-keys.md).
|
|
21
21
|
Production `stream Source.Stream` overrides and reaction/reducer `from Source[.Stream]`
|
|
22
22
|
select released v10: [routes and filters](production-routes-and-filters.md).
|
|
23
|
-
Qualifying non-route Double literals select
|
|
23
|
+
Qualifying non-route Double literals select v11;
|
|
24
24
|
`numbers exact` does not bind. Non-positional enum member numbers (`draft = 1`)
|
|
25
|
-
select
|
|
26
|
-
while specifications still use names.
|
|
25
|
+
select v12; positional pins keep earlier bytes/version,
|
|
26
|
+
while specifications still use names. Stage admits v12 and renders explicit numbers.
|
|
27
27
|
Syntax/example: command-surface `references/enum-numbers.md`.
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
Current pins: `versions.md` (the single table). Compile evidence below keeps its historical tool labels.
|
|
28
|
+
Published ESM versions never change meaning; later byte-changing features take a new version.
|
|
31
29
|
|
|
32
30
|
The syntax lives in compiled example files next to this one (each is a Markdown file holding
|
|
33
31
|
one complete `screenplay` fence). Copy shapes from them; do not write a form that none of
|
|
@@ -36,16 +34,16 @@ examples belong to `cheat-sheet-example.md` and its siblings.
|
|
|
36
34
|
|
|
37
35
|
| File | Mode | V1, warnings as errors | V3 (binds) |
|
|
38
36
|
| --- | --- | --- | --- |
|
|
39
|
-
| `cheat-sheet-example.md` | design: every construct family | 0 diagnostics, both tools (
|
|
37
|
+
| `cheat-sheet-example.md` | design: every construct family | 0 diagnostics, both tools (an older bundled compiler reported a false PLAY0285 on the `RecordingAPayment` cascade spec) | not ready by design (its header lists why; fewer blockers on the standalone tool) |
|
|
40
38
|
| `executable-example.md` | executable, StateChange and StateView | 0 diagnostics, both tools | ready, both tools |
|
|
41
39
|
| `pdl-example.md` | executable projections | 0 diagnostics, both tools | ready, both tools |
|
|
42
|
-
| `automation-translate-example.md` | executable Automation and Translate (ESM v6) | 0 diagnostics, both tools (
|
|
40
|
+
| `automation-translate-example.md` | executable Automation and Translate (ESM v6) | 0 diagnostics, both tools (an older bundled compiler could not bind it) | ready, both tools |
|
|
43
41
|
|
|
44
42
|
Screenplay sources: `Documentation/screenplay/grammar.md` (EBNF; checked against the parsers
|
|
45
43
|
by `for_Documentation/when_comparing_the_grammar_against_the_parsers.cs`),
|
|
46
44
|
`projections/grammar.md`, `captures/grammar.md`. Documentation examples compile in
|
|
47
45
|
Screenplay CI (`when_compiling_every_example.cs`) against repository main: the standalone
|
|
48
|
-
compiler
|
|
46
|
+
compiler; the compiler bundled in `cratis` can be older and lack the newest ESM versions.
|
|
49
47
|
|
|
50
48
|
## Samples and preview fixtures
|
|
51
49
|
|
|
@@ -53,7 +51,7 @@ Invoicing is a warning-free syntax showcase, not a runnable whole-language proof
|
|
|
53
51
|
The released samples policy excepts these preview families and points to dedicated
|
|
54
52
|
fixtures; do not infer binder admission from the sample's coverage list:
|
|
55
53
|
|
|
56
|
-
| Family | Screenplay
|
|
54
|
+
| Family | Screenplay fixture |
|
|
57
55
|
| --- | --- |
|
|
58
56
|
| Exact numbers | `Source/Screenplay/Compiler/Conformance/exact-named-rule-intent.play` |
|
|
59
57
|
| Sources/streams/command routes | `Documentation/screenplay/fixtures/source-streams.play` |
|
|
@@ -61,9 +59,8 @@ fixtures; do not infer binder admission from the sample's coverage list:
|
|
|
61
59
|
| Systems/operations/specification steps | `Documentation/screenplay/fixtures/operations.play` |
|
|
62
60
|
| Refusals/redelivery/no-events | `Source/Screenplay/Compiler/Conformance/reaction-refusals-redelivery.play`, `no-events.play` in that directory |
|
|
63
61
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
its old blanket PLAY0268 wording is not the current route verdict. Other rows
|
|
62
|
+
The Screenplay samples policy lists these preview families. Sources and specification routes
|
|
63
|
+
are admitted as v8 by the binder and runner, so a blanket PLAY0268 is not their verdict. Other rows
|
|
67
64
|
remain unadmitted. Compile and test each relevant fixture with the chosen tool.
|
|
68
65
|
|
|
69
66
|
## Lexical and structural rules
|
|
@@ -87,7 +84,7 @@ remain unadmitted. Compile and test each relevant fixture with the chosen tool.
|
|
|
87
84
|
generated identifier` (PLAY0484); legacy `?` is PLAY0479 (information).
|
|
88
85
|
- Ownership policies: `require claim "ownerId" matches subject` (subject = command identifier
|
|
89
86
|
or keyed query argument) or `matches <commandProperty>`; executable; renderable only for
|
|
90
|
-
text-backed targets
|
|
87
|
+
text-backed targets, Uuid and Date claim targets (see `renderable-subset.md`; unsupported subjects: STAGE-ESM-015).
|
|
91
88
|
|
|
92
89
|
## Exact numeric source mode
|
|
93
90
|
|
|
@@ -112,14 +109,14 @@ description, properties, `reads`, `authorize`, `validate`, `produces`/`handler`,
|
|
|
112
109
|
## `$context.` paths (command `produces`)
|
|
113
110
|
`occurred`, `tenant`, `command.<p>`, `arguments.<p>`, `causedBy.subject|name|userName`,
|
|
114
111
|
`causation.type`, `identity.id|name|userName|isAuthenticated|roles|claims.<n>`.
|
|
115
|
-
Binder-supported
|
|
112
|
+
Binder-supported: `occurred`, `identity.id` (= `causedBy.subject`),
|
|
116
113
|
`identity.name` (= `causedBy.name`), `identity.userName` (= `causedBy.userName`). `tenant`,
|
|
117
114
|
roles, claims, causation, `command.<p>`, `arguments.<p>`: PLAY0268. Binding is not execution:
|
|
118
115
|
a reference scenario that supplies only a clock carries no caller audit identity, so check the
|
|
119
116
|
reference runner before relying on identity paths in a specification. Renderable:
|
|
120
117
|
`$context.occurred` only.
|
|
121
118
|
|
|
122
|
-
|
|
119
|
+
`$identity.id`/`.name`/`.userName` map to the same ESM kinds as
|
|
123
120
|
`$context.identity`; prefer the shorter root, but the older one stays supported.
|
|
124
121
|
Other built-ins parse but roles/claims/authentication status do not bind in
|
|
125
122
|
produces mappings. Identity details are metadata: executable detail reads report
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
- Source reference and identifier checks
|
|
7
7
|
- Public events and translation direction
|
|
8
8
|
- Explicit enum member numbers
|
|
9
|
-
- Reserved stored names and event pins
|
|
9
|
+
- Reserved stored names and event pins
|
|
10
10
|
- Named keys, production routes and observer filters
|
|
11
11
|
- Caller identity, compliance and routes
|
|
12
12
|
- Specification metadata, callers, cases and locators
|
|
@@ -27,7 +27,7 @@ I (never fails, even with `--warnings-as-errors`). `PLAY` = compiler, `SP` = Arc
|
|
|
27
27
|
Where each layer appears: `screenplay <folder>` / `cratis screenplay validate` = syntax and
|
|
28
28
|
consistency (V1). MCP `executable-diagnostics` = binding (V2 reads them, V3 needs none:
|
|
29
29
|
PLAY0268-0274, 0350-0352, 0389, 0449). `cratis render` = binding with the bundled compiler,
|
|
30
|
-
then STAGE (V5 admission). Tool differences: `versions.
|
|
30
|
+
then STAGE (V5 admission). Tool differences: `../SKILL.md` ("Tool versions and the contract").
|
|
31
31
|
|
|
32
32
|
## Warnings that hide defects (always validate with `--warnings-as-errors`)
|
|
33
33
|
| Code | Meaning | Fix |
|
|
@@ -43,7 +43,7 @@ then STAGE (V5 admission). Tool differences: `versions.md`.
|
|
|
43
43
|
|
|
44
44
|
## Source reference and identifier checks
|
|
45
45
|
|
|
46
|
-
|
|
46
|
+
These are V1 source checks, not binding-only gaps:
|
|
47
47
|
|
|
48
48
|
| Code | Severity | Meaning |
|
|
49
49
|
| --- | --- | --- |
|
|
@@ -55,8 +55,7 @@ Legacy compliance spellings (`@pii`/`@sensitive`) do not evade PLAY0515.
|
|
|
55
55
|
|
|
56
56
|
## Public events and translation direction
|
|
57
57
|
|
|
58
|
-
|
|
59
|
-
ESM v9, except public/foreign imports without local shapes (PLAY0268).
|
|
58
|
+
All are errors. These constructs bind as ESM v9, except public/foreign imports without local shapes (PLAY0268).
|
|
60
59
|
|
|
61
60
|
| Code | Meaning / fix |
|
|
62
61
|
| --- | --- |
|
|
@@ -83,7 +82,7 @@ See automations-and-translations `references/public-events-and-direction.md`.
|
|
|
83
82
|
|
|
84
83
|
## Explicit enum member numbers
|
|
85
84
|
|
|
86
|
-
Source errors
|
|
85
|
+
Source errors; the pins bind as ESM v12:
|
|
87
86
|
|
|
88
87
|
| Code | Severity | Meaning / fix |
|
|
89
88
|
| --- | --- | --- |
|
|
@@ -96,28 +95,21 @@ Source errors from Screenplay 4.137.0; ESM v12 admission from 4.139.0:
|
|
|
96
95
|
Numbering errors have no automatic repair. PLAY0671 suggests the opt-in
|
|
97
96
|
`propose-number-enum-members` refactoring, not a correctness repair. Member names
|
|
98
97
|
remain specification values. Non-positional pins select v12; positional pins keep
|
|
99
|
-
older executable bytes/version. Consumer admission is separate
|
|
100
|
-
Source: `v4.139.0:Documentation/screenplay/diagnostics.md`, decision 0065.
|
|
98
|
+
older executable bytes/version. Consumer admission is separate.
|
|
101
99
|
|
|
102
|
-
## Reserved stored names and event pins
|
|
100
|
+
## Reserved stored names and event pins
|
|
103
101
|
|
|
104
102
|
| Code | Layer / severity | Meaning / fix |
|
|
105
103
|
| --- | --- | --- |
|
|
106
104
|
| PLAY0273 | Binding error | A stored source exactly `Default`, or stored stream exactly `All` (name or `id "All"` pin), is reserved. Authoring still parses/prints it. Rename the stream with discovered `propose-rename`; keeping `id "All"` cannot fix it. Comparison is ordinal: streams `all`, `ALL` and `Default` remain valid. Old `All` events read as source-only appends; moving history needs a Chronicle migration, not a language repair. |
|
|
107
105
|
| PLAY0472 | Binding error | An event pin is not a valid event-name identifier, effective stored names differ across generations, or two events share a stored name. Use a valid, application-unique stored name shared by all generations; never rename stored history merely to hide the error. |
|
|
108
|
-
| PLAY0686 | Retired |
|
|
106
|
+
| PLAY0686 | Retired | Differing event pins travel as `storedName` in ESM v16. MCP's compatibility `eventPinWarnings` array is empty. Renderer admission is separate: a renderer that does not admit v16 must refuse the model rather than render it under the new name. |
|
|
109
107
|
|
|
110
108
|
MCP readiness exposes the binding refusal. PLAY0273 is reused, not a new ESM
|
|
111
109
|
version; match its reserved-name message before choosing the rename.
|
|
112
110
|
Source/stream pins already travel in ESM v8; differing event pins require v16.
|
|
113
111
|
Equal-name event pins are no-ops; PLAY0471 removal preserves canonical bytes.
|
|
114
|
-
|
|
115
|
-
`Source/DotNET/Screenplay/Semantics/SemanticModelBinder.EventSources.cs:17-52` and
|
|
116
|
-
`decisions/0073-reserve-the-stored-event-stream-name-all.md:35-63`;
|
|
117
|
-
`v4.152.0:Documentation/screenplay/events.md:116-124`,
|
|
118
|
-
`Source/DotNET/Screenplay/Semantics/SemanticModelBinder.StoredEventNames.cs:15-35`,
|
|
119
|
-
`Source/DotNET/Screenplay.Mcp/McpWorkspaces.Refactoring.cs:82`.
|
|
120
|
-
Target evidence: `versions.md` (Stored-name rendering boundary).
|
|
112
|
+
Target evidence: a renderer must admit ESM v16 and preserve `storedName`, or refuse it.
|
|
121
113
|
|
|
122
114
|
## Named keys, production routes and observer filters
|
|
123
115
|
|
|
@@ -132,7 +124,7 @@ Target evidence: `versions.md` (Stored-name rendering boundary).
|
|
|
132
124
|
| PLAY0666 | W | Filter excludes all statically known effective producer routes; C# only, handlers/foreign origins suppress it |
|
|
133
125
|
|
|
134
126
|
Queries and trigger reads have no PLAY0661 repair. Composite view keys, query
|
|
135
|
-
blocks and their fixtures remain PLAY0268
|
|
127
|
+
blocks and their fixtures remain PLAY0268, while one explicit key binds
|
|
136
128
|
byte-identically to inference. Fixtures missing any part report PLAY0351.
|
|
137
129
|
Overrides/filters select released ESM v10; malformed routes also use PLAY0504.
|
|
138
130
|
Read read-surface `references/named-keys.md` and
|
|
@@ -140,9 +132,6 @@ Read read-surface `references/named-keys.md` and
|
|
|
140
132
|
|
|
141
133
|
## Caller identity, compliance and routes
|
|
142
134
|
|
|
143
|
-
Source authority: v4.127.0 `diagnostics.md`, `identity.md`, `concepts.md`,
|
|
144
|
-
`purposes.md`, `events.md`, `event-sources.md`, `reactions.md`.
|
|
145
|
-
|
|
146
135
|
| Code | Severity | Meaning / fix |
|
|
147
136
|
| --- | --- | --- |
|
|
148
137
|
| PLAY0152 | E | Bare `$identity` needs a property path |
|
|
@@ -193,10 +182,8 @@ escapes `%`/`|`, not an inferred split of legacy text.
|
|
|
193
182
|
|
|
194
183
|
Identity declarations and event `subject` are metadata; reading a declared
|
|
195
184
|
`$identity` detail in executable clauses is PLAY0268. `runs as` is admitted as
|
|
196
|
-
ESM v10
|
|
197
|
-
|
|
198
|
-
events with explicit subject marks still refuse PLAY0268. CLI 3.57.0's 4.147.1
|
|
199
|
-
bundle also binds concept compliance; purpose metadata is PLAY0270. See command-surface
|
|
185
|
+
ESM v10, not a PLAY0268 gap. Concept compliance binds as v13; enum/identity compliance and protected
|
|
186
|
+
events with explicit subject marks still refuse PLAY0268. Purpose metadata is PLAY0270. See command-surface
|
|
200
187
|
`references/compliance.md` and `references/context.md` for syntax and limits.
|
|
201
188
|
|
|
202
189
|
`screenplay_repair_capabilities` and `propose-repair` advertise PLAY0653: a
|
|
@@ -206,8 +193,6 @@ migration. Preview every repair; legal notes never move automatically.
|
|
|
206
193
|
|
|
207
194
|
## Specification metadata, callers, cases and locators
|
|
208
195
|
|
|
209
|
-
Authority: Screenplay v4.127.0 `diagnostics.md`, `specifications.md`, `slices.md`.
|
|
210
|
-
|
|
211
196
|
| Code | Severity | Meaning / fix |
|
|
212
197
|
| --- | --- | --- |
|
|
213
198
|
| PLAY0558 | E | Module/feature/slice/command/read-model/reaction documentation must be one nonempty fenced Markdown block; remove repeats or fix the fence. Events retain PLAY0477. |
|
|
@@ -292,8 +277,7 @@ C# CLI/MCP owns whole-application scoped diagnostics, opt-in completeness
|
|
|
292
277
|
checks PLAY0650/0651, semantic binding and PLAY0546 (a negated claim targets optional,
|
|
293
278
|
unavailable-subject or non-text data). The VS Code repair bridge is not a general
|
|
294
279
|
C# validator. A clean editor is not V1 for the complete application, V3 binding
|
|
295
|
-
or V4 execution. Run the CLI or MCP for those verdicts.
|
|
296
|
-
`v4.127.0:Documentation/screenplay/editor-diagnostics.md`, `diagnostics.md`.
|
|
280
|
+
or V4 execution. Run the CLI or MCP for those verdicts.
|
|
297
281
|
|
|
298
282
|
## Consistency errors (V1: the model contradicts itself)
|
|
299
283
|
| Code | Meaning |
|
|
@@ -301,7 +285,7 @@ or V4 execution. Run the CLI or MCP for those verdicts. Authority:
|
|
|
301
285
|
| PLAY0282 | `validate` rule targets a field absent from the command |
|
|
302
286
|
| PLAY0283 | `reads View by field` type matches no `by` param of the view's queries |
|
|
303
287
|
| PLAY0284 | `children`/`nested` never populates a declared element field |
|
|
304
|
-
| PLAY0285 | a spec's `then` event contradicts every possible declared producer of its `when` command (decidable literals, property copies, equality conditions). Fix the model or the spec deliberately. **False positive** on reaction cascades with
|
|
288
|
+
| PLAY0285 | a spec's `then` event contradicts every possible declared producer of its `when` command (decidable literals, property copies, equality conditions). Fix the model or the spec deliberately. **False positive** on reaction cascades with an older bundled compiler. On an older bundle confirm with the standalone tool, record a tool gap, do not "fix" a correct model |
|
|
305
289
|
| PLAY0286 | spec value is not a member of the enum |
|
|
306
290
|
| PLAY0287 | producer/capture/spec assigns a field the event lacks |
|
|
307
291
|
| PLAY0291-0294 | bad single-line JSON / unknown key / wrong shape / duplicate key |
|
|
@@ -309,7 +293,7 @@ or V4 execution. Run the CLI or MCP for those verdicts. Authority:
|
|
|
309
293
|
## Binding (V2 and V3) - see `executable-subset.md` for the full table
|
|
310
294
|
| Code | Meaning | Fix |
|
|
311
295
|
|---|---|---|
|
|
312
|
-
| PLAY0268 | construct the ESM cannot represent; read the message for the construct (`executable-subset.md` lists the common ones: handler, list or observable query, `pii`, `produces when` over read models, v6 constructs on
|
|
296
|
+
| PLAY0268 | construct the ESM cannot represent; read the message for the construct (`executable-subset.md` lists the common ones: handler, list or observable query, `pii`, `produces when` over read models, v6 constructs on an older bundled compiler) | stay in design mode, or change the construct if the domain allows; never strip `pii`/authorization |
|
|
313
297
|
| PLAY0269 / 0270 | UI deferred / authoring metadata (I) | none |
|
|
314
298
|
| PLAY0271 | legacy `reads` or a `concurrency` block keeps its legacy meaning and cannot bind (error) | design gap; a constraint for uniqueness; protected decisions are a target requirement |
|
|
315
299
|
| PLAY0273 | incoherent: ambiguous `for`, property not on event revision, operand type mismatch, derived `$eventContext` path | fix the reference |
|
|
@@ -321,7 +305,7 @@ or V4 execution. Run the CLI or MCP for those verdicts. Authority:
|
|
|
321
305
|
## Frequent errors
|
|
322
306
|
| Code | Meaning / fix |
|
|
323
307
|
|---|---|
|
|
324
|
-
| PLAY0001 | unknown top-level word (e.g. `slice` at top level of an un-imported file; `numbers` on
|
|
308
|
+
| PLAY0001 | unknown top-level word (e.g. `slice` at top level of an un-imported file; `numbers` on an older compiler) |
|
|
325
309
|
| PLAY0007 | a `concept` line is not `concept <Name> : <Type>` |
|
|
326
310
|
| PLAY0042 | a `produces` line is neither `produces <EventType>` nor `produces when <condition>` (the event goes on its own line and `for` on the line below) |
|
|
327
311
|
| PLAY0048 | a query body line opens with a word a query does not declare by (for example `observable` as a body line; it belongs in the return position) |
|
|
@@ -349,35 +333,31 @@ or V4 execution. Run the CLI or MCP for those verdicts. Authority:
|
|
|
349
333
|
| PLAY0480/0484 | modifier order `Type optional generated identifier` |
|
|
350
334
|
| PLAY0682 | `generate sequence` is reserved; keep the intended sequence as a capability gap |
|
|
351
335
|
| PLAY0683/0684 | PLAY0683: generated non-identifier below 64 random bits warns (a single-property unique constraint suppresses it); PLAY0684: generated identifier below 64 random bits is an error |
|
|
352
|
-
| PLAY0685 | own response name used under execute failure; outer successful responses remain available.
|
|
336
|
+
| PLAY0685 | own response name used under execute failure; outer successful responses remain available. UI composition `references/response-continuations.md` |
|
|
353
337
|
| PLAY0289 | (binding) no documents: empty root |
|
|
354
338
|
|
|
355
339
|
Fix order: E at V1 -> W at V1 -> silent-gap check -> V2 codes (if the mode needs V3).
|
|
356
340
|
Report each as `code file:line one-line meaning`; never paste more than about 30 lines.
|
|
357
341
|
|
|
358
342
|
## Render admission (V5): `STAGE-*`, `CLI-RENDER-*`, `STAGE-CRATIS-*`
|
|
359
|
-
Full table with causes: `renderable-subset.md`. The
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
refused; reducer filters render. Previous CLI 3.46.1 admitted through v7; its
|
|
365
|
-
v7 corpus received STAGE-ESM-028/029, not the older v7 version gate.
|
|
366
|
-
Codes in the historical snapshot:
|
|
343
|
+
Full table with causes: `renderable-subset.md`. The bundled renderer admits through a fixed
|
|
344
|
+
ESM version to construct checks; above it is CLI-RENDER-004 (direct Stage: STAGE-ESM-016).
|
|
345
|
+
Publication STAGE-ESM-032, foreign facts/event captures 033, claim-reading/opaque reaction gates
|
|
346
|
+
034, legacy filters 035 and production overrides 036 remain refused; reducer filters render.
|
|
347
|
+
|
|
367
348
|
| Code | Meaning |
|
|
368
349
|
|---|---|
|
|
369
|
-
| STAGE-ESM-016 | model above the admitted ESM schema
|
|
370
|
-
| STAGE-ESM-025 |
|
|
371
|
-
| STAGE-ESM-026 |
|
|
372
|
-
| STAGE-ESM-
|
|
373
|
-
|
|
|
374
|
-
| STAGE-ESM-
|
|
375
|
-
| STAGE-ESM-
|
|
376
|
-
| STAGE-ESM-
|
|
377
|
-
| STAGE-ESM-
|
|
378
|
-
| STAGE-ESM-
|
|
379
|
-
| STAGE-ESM-
|
|
380
|
-
| STAGE-ESM-019/022 | reducer body outside the pure allowlist |
|
|
350
|
+
| STAGE-ESM-016 | model above the admitted ESM schema: whole model refused |
|
|
351
|
+
| STAGE-ESM-025 | a typed-context member references a historical event revision or property identity; only the current revision renders |
|
|
352
|
+
| STAGE-ESM-026 | a selected event, or an event a selected scope depends on, is above its initial revision; Stage cannot render event-type migrations; gap-fill and hand-write the migrations |
|
|
353
|
+
| STAGE-ESM-001 | unsupported slice kind; `StateChange`, `StateView` and event-triggered `Automation` render, Translate is STAGE-ESM-024 |
|
|
354
|
+
| STAGE-ESM-004 / 006 / 013 | a `StateChange` without exactly one command; `produces` that cannot render (conditional, literal or computed mappings, duplicate tags); event-context value other than `$context.occurred` (reactions: `$context.causedBy.*`, `$context.eventSourceId`) |
|
|
355
|
+
| STAGE-ESM-005 / 015 | code rule or code validation bodies; authorization Stage cannot render exactly (role-claim URIs, nested or unresolved opaque policies, opaque-policy subjects that are not text, Uuid, Date or DateTime). Role-only, authenticated, opaque pure policies and Uuid/Date/DateTime/text claim targets render |
|
|
356
|
+
| STAGE-ESM-007 / 009 / 010 / 017 | projection shape (one projection or reducer per read model, affected-instance key, query delivery such as a snapshot list, keys, `all`, event-context values) |
|
|
357
|
+
| STAGE-ESM-011 | specification shape not rendered (`when append` outside the single-hop reaction subset, command specifications that cascade into reactions, composite values, an unauthenticated caller carrying roles or claims, v15 fixtures that do not match their strategy). Command scenarios and single-hop reaction appends render |
|
|
358
|
+
| STAGE-ESM-014 | constraint shape (multi-claim in one command, optional or composite targets) |
|
|
359
|
+
| STAGE-ESM-019/022 | reducer or opaque pure policy body outside the pure allowlist |
|
|
360
|
+
| STAGE-ESM-024 | interval, schedule, application, startup and shutdown triggers, opaque reaction bodies, captures, Translate, clock/trigger/capture specifications |
|
|
381
361
|
| STAGE-ESM-020 | a body the model requires is missing or changed (content hash check); blocks publication |
|
|
382
362
|
| STAGE-CRATIS-005 | a modeled artifact would render into `Customizations/` |
|
|
383
363
|
Fix by changing the model only where the domain allows it; otherwise the slice is gap-fill
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Executable example (StateChange and StateView)
|
|
2
2
|
|
|
3
|
-
A small model that compiles with 0 diagnostics and binds executable (`authoringAccepted` true, `executableReady` true, 0 executable diagnostics) on both tools when opened through MCP with a fixed root (see [mcp-loop.md](../../cratis-screenplay-model-authoring/references/mcp-loop.md) and [
|
|
3
|
+
A small model that compiles with 0 diagnostics and binds executable (`authoringAccepted` true, `executableReady` true, 0 executable diagnostics) on both tools when opened through MCP with a fixed root (see [mcp-loop.md](../../cratis-screenplay-model-authoring/references/mcp-loop.md) and [verdicts.md](verdicts.md)). Prose: [executable-subset.md](executable-subset.md).
|
|
4
4
|
|
|
5
5
|
```screenplay
|
|
6
6
|
// Executable example: StateChange + StateView, command and query protection, reference specifications.
|