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
Medium — two fidelity gaps in the shared diff engine (local file diff, snapshot compare, org compare).
What happens
Records load into a Map keyed by String(rec[matchField]) — Map.set keeps only the last row per key, no warning. The default org-compare key is Name, routinely non-unique: 3 rows named "Acme" → only one compared, summary.total undercounts, and with [Compare] Org-compare “Copy to target” inserts duplicates for Changed records #52 the wrong record can be synced.
Field comparison is String(sv ?? '') !== String(tv ?? '') — object values stringify to [object Object], so records whose nested values differ (Owner: {Name:'A'} vs {Name:'B'}) land in Unchanged.
Detect duplicate keys and surface a count/warning in the result and UI; JSON.stringify non-null object values before comparing (and display them the same way).
Environment
Commit 74cf21b (main), WaveLink 0.6.0. Found in the 2026-08-31 adversarial audit (code-verified).
Severity
Medium — two fidelity gaps in the shared diff engine (local file diff, snapshot compare, org compare).
What happens
Mapkeyed byString(rec[matchField])—Map.setkeeps only the last row per key, no warning. The default org-compare key isName, routinely non-unique: 3 rows named "Acme" → only one compared,summary.totalundercounts, and with [Compare] Org-compare “Copy to target” inserts duplicates for Changed records #52 the wrong record can be synced.String(sv ?? '') !== String(tv ?? '')— object values stringify to[object Object], so records whose nested values differ (Owner: {Name:'A'}vs{Name:'B'}) land in Unchanged.Evidence
src/ui/utils/dataDiff.ts:40-50(duplicates),:73(nested compare)tests/unit/dataDiff.test.ts:37covers blank keys only.Suggested fix
Detect duplicate keys and surface a count/warning in the result and UI;
JSON.stringifynon-null object values before comparing (and display them the same way).Environment
Commit
74cf21b(main), WaveLink 0.6.0. Found in the 2026-08-31 adversarial audit (code-verified).