From 20fb57258b923ed1b7bcbccaef47d659a4afc429 Mon Sep 17 00:00:00 2001 From: admin Date: Mon, 20 Jul 2026 04:38:53 +0000 Subject: [PATCH] Increase download timeout to 60 minutes for large MTGJSON files --- backend/app/services/mtgjson_manager.py | 2 +- state.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/backend/app/services/mtgjson_manager.py b/backend/app/services/mtgjson_manager.py index 134b64b..f694521 100644 --- a/backend/app/services/mtgjson_manager.py +++ b/backend/app/services/mtgjson_manager.py @@ -239,7 +239,7 @@ class MTGJSONManager: # Calculate timeout based on estimated file size # Large files (>100MB) get up to 60 minutes estimated_mb = self._get_estimated_size(filename) - timeout = max(1200, estimated_mb * 8) # At least 20 min, 8x estimated MB + timeout = max(3600, estimated_mb * 8) # At least 60 min, 8x estimated MB logger.info(f"Downloading {filename} from {url} (timeout: {timeout}s, est: {estimated_mb}MB)") diff --git a/state.json b/state.json index f7ad1ba..fac0a7c 100644 --- a/state.json +++ b/state.json @@ -1,6 +1,6 @@ { "task_description": "MTG Online Backend - MTGJSON Data Integration & Docker Deployment", - "current_step": "Timeouts doubled to prevent timeout errors", + "current_step": "Timeouts doubled to prevent download/upsert timeouts", "files_created": [ "backend/app/services/mtgjson_manager.py", "backend/scripts/sanity_check_mtgjson.py", @@ -35,6 +35,6 @@ "Check logs for sanity check results" ], "blockers": [], - "commit_hash": "0643544", + "commit_hash": "d347e0e", "timestamp": 1784598400 }