Skip to content

Commit 90f3888

Browse files
committed
wip(#15832): preserve in-progress Note 2 pin work after a container restart
NOT a finished change and NOT verified by the PM. The dispatched os-dev seat was extending the claim-probe pins and the engine-double ledger when the container restarted and killed it. This commit preserves that work; the merge of origin/main below it was the seat's own. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XpTx2tbq3pZRYAdoGt6E6Y
1 parent 51a362c commit 90f3888

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

packages/services/service-automation/src/suspended-run-claim-probe.test.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ import { SqlDriver } from '@objectstack/driver-sql';
9090
// through it so it physically cannot accept a call `ObjectQL.delete` refuses
9191
// (`scripts/check-engine-double-contract.mjs`), and the cases read it directly
9292
// to say WHICH route a recorded call would have taken.
93-
import { assertEngineDeleteDispatch } from '@objectstack/metadata-core';
93+
import { assertEngineDeleteDispatch, assertEngineUpdateDispatch } from '@objectstack/metadata-core';
9494

9595
import { AutomationEngine } from './engine.js';
9696
import { AutomationServicePlugin } from './plugin.js';
@@ -124,6 +124,8 @@ function createProbeAwareEngine(
124124
},
125125
async insert(_object, data) { rows.set(String(data.id), { ...data }); return data; },
126126
async update(_object, data, options) {
127+
// Refuses what a real server refuses (`check:engine-double-contract`).
128+
assertEngineUpdateDispatch(data, options as any);
127129
const id = options?.where?.id ?? data.id;
128130
rows.set(String(id), { ...(rows.get(String(id)) ?? { id }), ...data });
129131
return rows.get(String(id));

scripts/engine-double-contract.pinned.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3381,6 +3381,16 @@
33813381
"verb": "update",
33823382
"pinned": 1
33833383
},
3384+
{
3385+
"file": "packages/services/service-automation/src/suspended-run-claim-probe.test.ts",
3386+
"verb": "delete",
3387+
"pinned": 1
3388+
},
3389+
{
3390+
"file": "packages/services/service-automation/src/suspended-run-claim-probe.test.ts",
3391+
"verb": "update",
3392+
"pinned": 1
3393+
},
33843394
{
33853395
"file": "packages/services/service-automation/src/suspended-run-store.test.ts",
33863396
"verb": "delete",

0 commit comments

Comments
 (0)