Repository navigation
0.70.0
Named rows beside a row set, state wire spellings, and replays that no longer stop with InvalidReplay.
8 added, 3 changed (1 breaking), 9 fixed.
Breaking
- Breaking for generated code of a variant that declares
code:: a variant'scode:,{name: call.started, code: Begun}, names its identifier in the codeess generate synthesizegenerates for Rust, Web and Go, as a declaration'snaming: {code: …}does, while the wire value stayscall.started(#662). It validated before and every target ignored it, though the Rust collision refusal named it as the remedy. A model that declarescode:on a variant sees that variant's generated identifier move to the one it wrote. A written code the target cannot use is refused asinvalid-identifierwhere it is written, and the refusal names the code:Selfon Rust and Web, and on Go any code that is not an exported identifier, such asbegunortype. Go holds a declaration'snaming: {code: …}to the same rule; before, it emitted such a code verbatim into a module that did not compile.
Changed
- From
format: ess/32one command may guard on rows its input names,when_related: {via: input.<field>, exists: false | predicate: …}, beside a row-set guard,when_related: {entity, where, exists | count | forall}, as an adopter asked (#554): "connect two ports that exist and face the right way, unless a wire already leaves the source" is one command. The one precedence rule answers a missing named row first, in declaration order, then every refusal over a present named row or a row set in declaration order, then the accepting branches; the interpreter follows it, synthesis witnesses each branch it can arrange on rows the declared commands create and names the branch it cannot, asESS-SYNTH-001does, and generated Rust and Go keep such a command an obligation, named. Belowess/32the pair keeps itsunsupported_construct, its message unchanged and its hint namingess/32; awhen_subjectguard beside a row set keeps it at every format. - From
format: ess/32a struct may declare no fields,fields: [], as an adopter asked (#649). Open (undeclared_fields: ignored), any object is a value and the schemas admit any member; closed, only{}is, and TypeScript realizes it asRecord<string, never>. The generated Rust decoder refuses a value that is no object, as the Go decoder does. Belowess/32an empty struct keepsESS-TYPE-007, its message unchanged and its hint namingess/32. An enum or a union with no variants is still refused at every format. - From
format: ess/32a lifecycle state may declare its wire spelling,states: [{name: Indexing, wire: indexing}, Ready], as two adopters asked (#639). JSON Schema, OpenAPI, AsyncAPI and the generated Rust, Go and TypeScript spell the stateindexingand refuseIndexing; guards, transitions and conformance suites keep the declared name. Two states spelled alike are refused asconflicting_declaration. Belowess/32the mapping is refused asunsupported_format_versionnamingess/32at the state, where it was a whole-fileinvalid type: map.ess verify diffreports a changed spelling asVariantWireNameChangedon<Entity>.State, and Entity Runtime lowering refuses a spelled state asStateWireNameUnsupported. A view ordered by a respelled state keeps its generated query an obligation, as one ordered by a respelled enum does. - The synthesized Rust server's
wiremodule decodes published events, as an adopter asked.decode_system_eventreads the envelopeencode_system_eventwrites,{"event": …, "payload": {…}}, back into the system'sSystemEvent. Each event gets its owndecode_event_<name>, which reads every payload field under its declared wire name and refuses a payload that is not an object. An envelope naming an event the system does not publish is refused, and the refusal names that event. The web bridge'swiremodule gains the same per-event decoders. Existing functions keep their signatures. - The synthesized Rust server's surface modules gain
dispatch_with_eventsandhandle_with_events, as an adopter asked. Each answers whatdispatchandhandleanswer and also returns every typed event published while the call ran, in log order: the command's own events, what its bindings published in turn, and what a held-back delivery retried during the call published. Events already on the system's log when the call started are not the call's and are not returned. A call refused before the command runs returns an empty list.dispatch,handleandservekeep their signatures and answer the same bytes. The Go server has no public dispatch or codecs and is unchanged. ess-conformancemakes the interpreted target's minting and view ordering public, as an adopter asked, in a new moduleinterpret::values.mint(ir, type, tick)answers the value the interpreter mints for that type on the scenario counter'stick-th draw, counting from 1, andNonefor anOptionaltype.order_view_rows(ir, view, rows)sorts rows into the order the interpreter answers that view in; rows tied on everyorder_bykey keep the caller's order. The interpreter calls these two functions itself, so a renderer or preview that calls them shows the identifiers and row order the interpreter does, without a copy that drifts. Both answer the interpreter's own choice, not a rule of the specification, and may change in a later release.ess generate typestakes--check, as the other generating commands do, as an adopter asked (#654). With the arguments that wrote a library and its--out, it compares the files the command would write with what--outholds and writes nothing: it exits 0 when the library is current and 1 with one line per file that is missing, differs, or is recorded in.ess-outputand no longer generated, each namingess generate types. A copy of the library at another path checks clean, and a file.ess-outputdoes not record is not drift.--checkrequires--out.- 12 more in the changelog.
Every change: CHANGELOG.md § 0.70.0
Adopter replay (reported by the adopters, not verified by ess)
- on integrate/ess-0700 8a4fdbe built locally, a 9-domain adopter specification gives 1105 scenarios / 41 refusals at ess/25, ess/31 and ess/32, where 0.69.2 stopped with InvalidReplay at ess/31. The 41 refusals have the causes reported before (filed as 0.71.0 stories).
- on integrate/ess-0700 8a4fdbe built locally, a second adopter specification goes from 42 scenarios / 7 refusals to 46 / 3; the 4 Decimal wrong-state refusals are gone.