fix(test): test_849 expects 3 begin_nested/lot after #1921 upsert-reconcile SAVEPOINT — unblock red main gate #1925

Merged
bot-backend merged 1 commit from fix/test-849-savepoint-count-1921 into main 2026-06-26 17:23:24 +00:00
Collaborator

Red main gate — все tradein-деплои застряли

После моего деплоя 2fe34ac (green) в main влились #1919/#1921/#1922. Коммит 197068c (#1921, "save_listings UPDATE by (source,source_id)") добавил per-lot SAVEPOINT вокруг listings-upsert: ловит IntegrityError на UNIQUE(source,source_id) (migration 133) при dedup_hash-дрейфе → rollback SAVEPOINT'а + прямой UPDATE. Это легитимный 3-й begin_nested/лот (upsert + snapshot + hook).

test_849_matching_savepoint::test_no_begin_nested_inside_link_listing_to_house ассертил == 2*len(lots) (snapshot + hook) — прокси устарел → детерминированный fail (got 9, expected 6). Это завалило deploy-test-gate, а он serialized-блокирует build+deploy → #1921, #1922 и мой #1924 (geom GIST индекс) не доехали до прода (стоят на 2fe34ac).

Фикс

Обновил ожидание до 3 * len(lots) + комментарий про 3 SAVEPOINT'а. Интент теста сохранён: хук (_link_listing_to_house) по-прежнему НЕ открывает внутренний SAVEPOINT (base.py:715) — это и проверяется. Код #1921 корректен (это companion-фикс к моей migration 133), правится только тест.

Локально полный CI-прогон: 2413 passed, 1 skipped, 2 deselected, 0 failed (та же команда, что в deploy-test).

После merge зелёный гейт выпустит на прод застрявшие #1921 (avito reconcile) + #1922 (UI pack) + #1924 (geom GIST, #1189) одним деплоем.

Refs #1921, #849, #1189

## Red main gate — все tradein-деплои застряли После моего деплоя 2fe34ac (green) в main влились #1919/#1921/#1922. Коммит **197068c** (#1921, "save_listings UPDATE by (source,source_id)") добавил per-lot SAVEPOINT вокруг listings-upsert: ловит `IntegrityError` на `UNIQUE(source,source_id)` (migration 133) при dedup_hash-дрейфе → rollback SAVEPOINT'а + прямой UPDATE. Это **легитимный 3-й** `begin_nested`/лот (upsert + snapshot + hook). `test_849_matching_savepoint::test_no_begin_nested_inside_link_listing_to_house` ассертил `== 2*len(lots)` (snapshot + hook) — прокси устарел → **детерминированный fail** (got 9, expected 6). Это завалило deploy-`test`-gate, а он serialized-блокирует build+deploy → #1921, #1922 и мой #1924 (geom GIST индекс) **не доехали до прода** (стоят на 2fe34ac). ## Фикс Обновил ожидание до `3 * len(lots)` + комментарий про 3 SAVEPOINT'а. Интент теста сохранён: хук (`_link_listing_to_house`) по-прежнему НЕ открывает внутренний SAVEPOINT (base.py:715) — это и проверяется. Код #1921 корректен (это companion-фикс к моей migration 133), правится только тест. Локально полный CI-прогон: **2413 passed, 1 skipped, 2 deselected, 0 failed** (та же команда, что в deploy-`test`). После merge зелёный гейт выпустит на прод застрявшие #1921 (avito reconcile) + #1922 (UI pack) + #1924 (geom GIST, #1189) одним деплоем. Refs #1921, #849, #1189
bot-backend added 1 commit 2026-06-26 17:22:54 +00:00
fix(test): test_849 expects 3 begin_nested/lot after upsert-reconcile SAVEPOINT (#1921)
All checks were successful
CI / changes (pull_request) Successful in 6s
CI / backend-tests (pull_request) Has been skipped
CI / frontend-tests (pull_request) Has been skipped
CI / openapi-codegen-check (pull_request) Has been skipped
731f5538a5
197068c (#1921) added a per-lot SAVEPOINT around the listings upsert to catch
IntegrityError on UNIQUE(source,source_id) (migration 133) and reconcile via UPDATE.
That's a legit 3rd begin_nested/lot (upsert + snapshot + hook), so the test's
== 2*len(lots) proxy was stale → red main gate blocking all tradein deploys.
Hook itself still opens no inner SAVEPOINT (base.py:715) — test intent preserved.
bot-backend merged commit 87364eebca into main 2026-06-26 17:23:24 +00:00
bot-backend deleted branch fix/test-849-savepoint-count-1921 2026-06-26 17:23:25 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: lekss361/gendesign#1925
No description provided.