|
All checks were successful
CI / changes (push) Successful in 6s
CI / changes (pull_request) Successful in 6s
CI / frontend-tests (push) Has been skipped
CI / frontend-tests (pull_request) Has been skipped
CI / backend-tests (push) Successful in 6m22s
CI / backend-tests (pull_request) Successful in 6m24s
_SALES_WINDOW_SQL делал GROUP BY ROLLUP (rooms_int), rooms_int nullable (ETL пишет NULL для «неопределённого типа», sales_series.py:399 явно обрабатывает None). Проданный лот с rooms_int IS NULL даёт ДВЕ строки rooms_int IS NULL (NULL-группа + grand-total итог), неразличимые в Python (оба if r["rooms_int"] is None). MixedAggregate-план PG16 эмитит grand-total ПЕРВЫМ (среди hash-строк), NULL-группа после → loop затирает units_total частичным счётом (живой тест на PG16: 2000 → 200). Эффект: unit_velocity / absorption_rate занижены, months_of_supply завышен → base_pace в demand_supply_forecast неверный (recommendation.py:586) → reports/scoring врёт. Patch: - SQL: добавить GROUPING(rooms_int) AS is_total (=1 для grand-total). - Python: ветвить по is_total, NULL-комнатную группу класть в by_room['unknown'] (отдельный бакет), аккумулировать через += вместо assign (защита от будущих NULL-вариантов). - Тесты: моки получили "is_total" поле (1 для grand-total, 0 иначе). 71/71 market_metrics тестов зелёные. ruff clean. Closes #1214 |
||
|---|---|---|
| .. | ||
| api | ||
| fixtures | ||
| integration | ||
| scrapers | ||
| scripts | ||
| services | ||
| smoke | ||
| sql | ||
| workers | ||
| __init__.py | ||
| conftest.py | ||
| test_admin_weight_profiles.py | ||
| test_audit_middleware.py | ||
| test_concepts_stub.py | ||
| test_ekb_geoportal_client.py | ||
| test_gate_verdict.py | ||
| test_health.py | ||
| test_layout_signature.py | ||
| test_layout_tz_pdf.py | ||
| test_nspd_client.py | ||
| test_nspd_sync.py | ||
| test_ping.py | ||
| test_poi_score.py | ||
| test_quarter_dump_lookup.py | ||
| test_rbac.py | ||
| test_sentry_init.py | ||
| test_velocity.py | ||
| test_weight_profiles.py | ||