- cross-province groups now pair ns<->nb by completeness (img > km > older)
up to min per region instead of collapsing the whole group to one row;
surplus siblings (multi-unit dealer ads) stay active — no false merges
- verified on live DB: dup 80 -> 77, active 560 -> 563, total 640; the 3
freed rows are the BMW G 310 R dealer siblings (450/451/452); deck top
order unchanged (Indian Scout 91 x3 then Vulcan 900 73); re-import
idempotent (77 stable)
- selfcheck +2: multi-unit pairing semantics, reversibility (flip to
active + re-import re-derives the pairing) — 16/16 green
- db.init_db gains guarded ALTER TABLE additions for listings.year /
seller_type / extras (schema.sql v1 untouched; PRAGMA-checked idempotent)
- rubric: extras_from_text() returns matched EXTRAS labels (table order)
- importer: normalize computes year (existing helper), seller_type ONLY
from a real state-item signal (dealer/private, else NULL), extras JSON;
upsert rewrites the new columns on both paths
- verified on live DB: import idempotent, counts stay 640/560/80, year
backfilled on 599 rows, extras on 45, seller_type 0 (no state signal)