|
Some checks failed
Deploy / build-backend (push) Blocked by required conditions
Deploy / build-worker (push) Blocked by required conditions
Deploy / build-frontend (push) Blocked by required conditions
Deploy / deploy (push) Blocked by required conditions
Deploy / changes (push) Has been cancelled
objective_lots.district хранит МИКРО-вокабуляр ('Уралмаш', 'ЖБИ', ...).
_query_artificial_demand фильтровал сырым АДМИН-именем ('Кировский' с
forecast.py:123) → ol.district='Кировский' = 0 строк → n_sold=0 → §25.5
Artificial Demand 'unavailable' с ложной причиной «нет проданных лотов»
в каждом district-scoped отчёте. Тот же класс бага, что #1211 в
_price_sensitivity.
Patch: импорт resolve_objective_districts + замена сырого
`ol.district = CAST(:district AS text)` на зеркальный паттерн
sales_series._SOURCE_B_SQL / market_metrics._SALES_WINDOW_SQL:
(CAST(:has_district AS boolean) IS FALSE
OR ol.district = ANY(CAST(:districts AS text[])))
Сигнатура _query_artificial_demand / _build_artificial_demand НЕ меняется
— caller остаётся admin-aware на входе.
+5 новых тестов (TestArtificialDemandDistrictResolution: резолвер вызван,
микро в bind, n_sold>0 после фикса), 6 обновлённых SQL-тестов. 21 passed
artificial_demand + 1030 forecasting тестов зелёные. ruff clean.
Closes #1205
|
||
|---|---|---|
| .. | ||
| analysis_runs | ||
| cadastre | ||
| chat | ||
| exporters | ||
| forecasting | ||
| llm | ||
| scrapers | ||
| site_finder | ||
| __init__.py | ||
| test_cadastre_bulk.py | ||
| test_ekburg_permits.py | ||
| test_forecast_request_cache.py | ||
| test_functional_zone_lookup.py | ||
| test_granddoc_lookup.py | ||
| test_ird_analyze.py | ||
| test_ird_overlay_lookup.py | ||
| test_krt_lookup.py | ||
| test_newbuilding_crossload.py | ||
| test_nspd_denorm.py | ||
| test_objective_backfill.py | ||
| test_own_developer_ids_config.py | ||
| test_planning_lookup.py | ||
| test_quarter_dump_lookup.py | ||
| test_recommend_mix_velocity.py | ||
| test_reservation_lookup.py | ||
| test_weather_cache.py | ||
| test_zone_regulation_extract.py | ||