gendesign/tradein-mvp/backend/app
bot-backend d688d24a12 fix(tradein): sync n_analogs to anchor count when anchor drives headline (#695)
QA-fail after #738: that PR de-contradicted the explanation STRING, but
n_analogs stayed = radius count (listings_clean) while the same-building anchor
(#691/#694) replaced the headline + analogs list with the house comps. So every
UI counter («Аналогов N», «Показано N из M», «по N аналогам», histogram) still
read the radius number — producing «Показано 5 из 4» on the Олимп penthouse
(radius=4, anchor=5). #738's Малышева case passed only because radius==anchor
(14=14) — mimicry, not a fix.

Fix: when anchor_tier is not None, set n_analogs = anchor['n'] (the comp count
the estimate is actually built on, = the displayed analogs capped at 10). All
counters now agree. Per #698, for the anchor path that IS the «full count found».
Radius path unchanged.

Refs #695
2026-05-30 18:23:30 +03:00
..
api feat(tradein): add data_quality flag to /sales-vs-listings (#721) (#723) 2026-05-30 13:21:08 +00:00
core feat(tradein): brand-by-account + result IA redesign (distinct asking/sale prices) (#683) 2026-05-30 06:45:14 +00:00
observability feat(tradein): enrich GlitchTip SDK init — integrations + PII scrub (#396) (#643) 2026-05-29 09:23:17 +00:00
schemas docs(tradein): clarify n_analogs vs analogs[] top-10 cap (#698) (#737) 2026-05-30 15:00:48 +00:00
services fix(tradein): sync n_analogs to anchor count when anchor drives headline (#695) 2026-05-30 18:23:30 +03:00
tasks feat(tradein): daily asking→sold ratio refresh (#648 S4) (#663) 2026-05-29 13:49:36 +00:00
__init__.py feat: add tradein-mvp subproject (Trade-In Estimator под /trade-in) 2026-05-21 00:25:39 +03:00
main.py feat(tradein): enrich GlitchTip SDK init — integrations + PII scrub (#396) (#643) 2026-05-29 09:23:17 +00:00