--- model: gpt-5.6-sol provider: openai service: opencode timestamp: 2026-07-28T23:27:18Z git_ref: ed85721c diff_cmd: git diff HEAD~1..HEAD --- > `git diff HEAD~1..HEAD -- piker/storage/nativedb.py tests/test_storage_nativedb.py` Fixed incremental NativeDB updates against legacy persisted history with non-positive timestamps. Incoming provider frames remain strictly validated, while merge repair discards invalid persisted rows before concat, dedupe, ordering, canonical-index rewrite, and atomic publication. The regression reproduces the observed MNQ baseline shape: one epoch-zero row, noncanonical absolute indexes, extra derived columns, and a valid fresh IB frame. It proves the invalid row is removed while all valid old and new bars survive with canonical indexes. Verification generated with the patch: - NativeDB regressions: 18 passed - history backfill regressions: 6 passed - focused Ruff: passed - `git diff --check`: passed