@lmzhen/dsh-evolution-state-storage 0.3.61 → 0.3.62

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.
@@ -81,8 +81,14 @@ export interface EvolutionStateStorage {
81
81
  transactCuratorState(task: (current: CuratorStateRecord | null) => CuratorStateRecord | null): Promise<void>;
82
82
  listPending(status?: PendingStatus): Promise<PendingRecord[]>;
83
83
  savePending(record: PendingRecord): Promise<void>;
84
- /** Atomically transition a pending record exactly once. */
85
- tryResolvePending(id: string, status: Exclude<PendingStatus, 'pending'>): Promise<PendingResolution>;
84
+ /**
85
+ * Atomically transition a pending record exactly once.
86
+ * @param expectedClaimId - when given, the transition applies only while the
87
+ * record is STILL claimed by this approver (P2-2, v14). A record resolved or
88
+ * re-claimed by another writer is left untouched and reported as
89
+ * `applied: false`, so an approve can never overwrite a concurrent reject.
90
+ */
91
+ tryResolvePending(id: string, status: Exclude<PendingStatus, 'pending'>, expectedClaimId?: string): Promise<PendingResolution>;
86
92
  /** Atomically mark a pending record as claimed by one approver, or return null. */
87
93
  claimPending(id: string, claimId: string): Promise<PendingRecord | null>;
88
94
  /** Release this claim when the replay runner cannot complete. */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@lmzhen/dsh-evolution-state-storage",
3
3
  "description": "Provider registry seam for durable evolution state (community build)",
4
- "version": "0.3.61",
4
+ "version": "0.3.62",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },