@reventlessdev/reventless-core 3.0.0-alpha.257 → 3.0.0-alpha.258

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/CHANGELOG.md CHANGED
@@ -3,6 +3,13 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # 3.0.0-alpha.258 (2026-09-07)
7
+
8
+ ### Bug Fixes
9
+
10
+ * **core:** a state view slice composes its [@display](https://github.com/display)Name like a read model ([851aa1d](https://github.com/ReventlessDev/reventless-core/commit/851aa1d12ddae9dd39f91084f5719cd98fe1cbd4))
11
+
12
+
6
13
  # 3.0.0-alpha.257 (2026-09-07)
7
14
 
8
15
  ### Bug Fixes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reventlessdev/reventless-core",
3
- "version": "3.0.0-alpha.257",
3
+ "version": "3.0.0-alpha.258",
4
4
  "description": "Core package for Reventless framework",
5
5
  "license": "Apache-2.0",
6
6
  "jest": {
@@ -29,16 +29,16 @@
29
29
  "sury": "11.0.0-rc.2",
30
30
  "uuid": "^13.0.0",
31
31
  "@reventlessdev/rescript-effect": "0.1.0-alpha.32",
32
- "@reventlessdev/rescript-fast-csv": "2.0.0-alpha.9",
33
32
  "@reventlessdev/rescript-hash-object": "1.2.0-alpha.14",
33
+ "@reventlessdev/rescript-fast-csv": "2.0.0-alpha.9",
34
34
  "@reventlessdev/rescript-node": "2.0.0-alpha.9",
35
35
  "@reventlessdev/rescript-jest": "1.0.0-alpha.10",
36
- "@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.19",
37
36
  "@reventlessdev/rescript-ssh2": "2.0.0-alpha.9",
38
- "@reventlessdev/reventless-interop": "3.0.0-alpha.35",
39
- "@reventlessdev/reventless-spec": "3.0.0-alpha.130",
40
- "@reventlessdev/reventless-infra": "3.0.0-alpha.158",
41
- "@reventlessdev/rescript-uuid": "2.0.0-alpha.0"
37
+ "@reventlessdev/reventless-infra": "3.0.0-alpha.159",
38
+ "@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.19",
39
+ "@reventlessdev/rescript-uuid": "2.0.0-alpha.0",
40
+ "@reventlessdev/reventless-spec": "3.0.0-alpha.131",
41
+ "@reventlessdev/reventless-interop": "3.0.0-alpha.35"
42
42
  },
43
43
  "devDependencies": {
44
44
  "rescript": "12.3.0",
@@ -154,11 +154,16 @@ module Make = (
154
154
  })
155
155
  ->Array.flat
156
156
  ->Array.reduce(Effect.succeed(), (acc, action) =>
157
- acc->Effect.flatMap(_ =>
157
+ acc->Effect.flatMap(_ => {
158
+ // A slice's state carries the same synthetic `displayName` the
159
+ // ppx injects for a read model's, so it is composed on the same
160
+ // terms — without this the column stays null and every surface
161
+ // names the row by its id.
162
+ let action = FrameworkProjection.rewriteAction(action, Spec.stateSchema)
158
163
  Effect.promise(() =>
159
164
  FrameworkProjection.handleAction(~comp, action, projectionOps, Spec.subIdConfig)
160
165
  )->Effect.map(_ => ())
161
- )
166
+ })
162
167
  )
163
168
  })
164
169
 
@@ -121,7 +121,10 @@ function Make(RuntimeEnvironment) {
121
121
  let fieldsStr = f === "" ? "" : `({` + f + `})`;
122
122
  Effect.runSync(EffectLogger$ReventlessCore.logInfo(comp, dataDict, `handling event ` + idxStr + `/` + total + `: ` + LogFormat$ReventlessCore.bold(eventType) + fieldsStr + ` ` + actionsStr));
123
123
  return actions;
124
- }).flat(), Effect.succeed(), (acc, action) => Effect.flatMap(acc, () => Effect.map(Effect.promise(() => Projection$ReventlessCore.handleAction(comp, action, projectionOps, Spec.subIdConfig)), param => {})));
124
+ }).flat(), Effect.succeed(), (acc, action) => Effect.flatMap(acc, () => {
125
+ let action$1 = Projection$ReventlessCore.rewriteAction(action, Spec.stateSchema);
126
+ return Effect.map(Effect.promise(() => Projection$ReventlessCore.handleAction(comp, action$1, projectionOps, Spec.subIdConfig)), param => {});
127
+ }));
125
128
  });
126
129
  let handler = SpecificEventCollector.makeHandler(ec, jsonEventsHandler);
127
130
  let resources = Component$ReventlessCore.outputs(queryDb).resources;
@@ -47,7 +47,9 @@ module Make = (
47
47
  ~detail=raw.data,
48
48
  `handling event ${idx.contents->Int.toString}/${count}: ${LogFormat.bold(raw.eventType)}(${id}) ${actionsStr}`,
49
49
  )->Effect.runSync
50
- allActions->Array.pushMany(actions)
50
+ allActions->Array.pushMany(
51
+ actions->Array.map(FrameworkProjection.rewriteAction(_, Spec.stateSchema)),
52
+ )
51
53
  Some(event)
52
54
  | None => None
53
55
  }
@@ -35,7 +35,7 @@ function Make(Spec) {
35
35
  });
36
36
  let actionsStr = LogFormat$ReventlessCore.actionNames(actions);
37
37
  Effect.runSync(EffectLogger$ReventlessCore.logInfo(comp, raw.data, `handling event ` + idx.contents.toString() + `/` + count + `: ` + LogFormat$ReventlessCore.bold(raw.eventType) + `(` + id + `) ` + actionsStr));
38
- allActions.push(...actions);
38
+ allActions.push(...actions.map(__x => Projection$ReventlessCore.rewriteAction(__x, Spec.stateSchema)));
39
39
  return Primitive_option.some(event);
40
40
  });
41
41
  let skipped = rawEvents.length - events.length | 0;