From 7e5ccdbb83834054a34746b6443c25a6c5176807 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=AE=D1=80=D0=B8=D0=B9=20=D0=A7=D0=B5=D1=80=D0=BD=D0=B5?= =?UTF-8?q?=D0=BD=D0=BA=D0=BE?= Date: Mon, 27 Oct 2025 21:06:14 +0300 Subject: [PATCH] =?UTF-8?q?=D1=81=D1=87=D0=B5=D1=82=20=D0=BF=D0=BE=20?= =?UTF-8?q?=D1=87=D0=B5=D1=82=D0=B2=D0=B5=D1=80=D1=82=D1=8F=D0=BC=20=D0=B2?= =?UTF-8?q?=20=D0=BE=D1=82=D0=BE=D0=B1=D1=80=D0=B0=D0=B6=D0=B5=D0=BD=D0=B8?= =?UTF-8?q?=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- get_data_new.py | 5 +---- visual.py | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/get_data_new.py b/get_data_new.py index c5342df..5048558 100644 --- a/get_data_new.py +++ b/get_data_new.py @@ -794,7 +794,7 @@ def render_once_after_game( try: logger.info(f"[RENDER_ONCE] Fetching final game snapshot for game_id={game_id}") # === 1. один запрос к API (ручка "game") === - fetch_api_data( + state = fetch_api_data( session, "game", host=HOST, @@ -802,9 +802,6 @@ def render_once_after_game( lang=lang, ) - # === 2. собрать state из свежего api_game.json === - state = build_render_state() - # === 3. прогнать вычисления как в render_loop === Team_Both_Stat(state) Json_Team_Generation(state, who="team1") diff --git a/visual.py b/visual.py index 72ce379..a1edbab 100644 --- a/visual.py +++ b/visual.py @@ -616,7 +616,7 @@ if isinstance(cached_game_online, dict): if isinstance(cached_game_online, dict) and ( - (cached_game_online.get("result") or {}).get("plays") or [] + cached_game_online.get("plays") or [] ): col_1_col = [f"col_1_{i}" for i in range(1, period_max + 1)] col_2_col = [f"col_2_{i}" for i in range(1, period_max + 1)]