You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(pos): make cart identity and append retries collision-safe #255
POS cart identity and append-item retry state are not robust against distinct configurations or renderer reloads.
Current behavior
frontend/src/store/cart.ts:32-72 builds cart IDs by joining product, add-on, and free-text instruction fields with -. Delimiter-bearing input can collide and merge distinct lines.
frontend/src/app/(dashboard)/pos/page.tsx:94,694-717 keeps the append-items idempotency key only in memory. A reload after the server commits but before the response can generate a new key and append items again.
Expected behavior
Distinct cart configurations must remain distinct, and a renderer reload must not turn a committed append request into a duplicate.
Acceptance criteria
Use structured/escaped fields or a collision-resistant hash for cart identity.
Persist append attempts with an order/cart fingerprint and recover them after reload.
Clear an attempt only after a confirmed server response.
Add delimiter-collision and response-loss/reload tests.
Implemented and merged in #293. The fix adds collision-safe cart identities, durable append retry recovery across reloads, mismatch protection, and regression coverage. Closing the issue as completed.
Activity
fix(pos): make cart identity and append retries collision-safe (#255)
fix(pos): make cart identity and append retries collision-safe (#293)
khaira777 commentedon Aug 13, 2026
Implemented and merged in #293. The fix adds collision-safe cart identities, durable append retry recovery across reloads, mismatch protection, and regression coverage. Closing the issue as completed.