fix(tradein): distinct asking median vs expected-sold price (no double-discount) #682

Merged
bot-reviewer merged 1 commit from fix/tradein-expected-sold-distinct into main 2026-05-30 06:35:46 +00:00

1 commit

Author SHA1 Message Date
lekss361
d9e0bfd541 fix(tradein): distinct asking median vs expected-sold price (no double-discount)
Same-building anchor set the headline median from anchor_sold_ppm2 (band-haircut
already applied), then forced expected_sold == headline. With the per-rooms
asking_to_sold_ratio also attached, the UI showed two identical numbers
('Ориентир запроса' == 'Ожидаемая цена продажи') + a mismatched -N% badge.
Fix: headline uses anchor_ppm2 (ASKING space); expected_sold = median × ratio
(single asking->sold mechanism) → distinct, strictly lower; null-guard preserved.
Median now asking-space (closer to golden asking reals; Хохрякова 48 4к 98.6M).
227 estimator tests pass; ruff clean.

Refs #651 #677
2026-05-30 09:29:18 +03:00