Merge pull request #1130 from jamiepine/prep/pr-1112

Fix infinite HF retry storm when loading a cached model offline
This commit is contained in:
capy-ai-staging[bot]
2026-10-04 00:05:46 +00:00
committed by GitHub
8 changed files with 351 additions and 90 deletions
+3 -1
View File
@@ -15,6 +15,7 @@ from typing import Callable, List, Optional, Tuple
import numpy as np
from ..utils.audio import normalize_audio, load_audio
from ..utils.hf_offline_patch import force_offline_if_cached
from ..utils.progress import get_progress_manager
from ..utils.hf_progress import HFProgressTracker, create_hf_progress_callback
from ..utils.tasks import get_task_manager
@@ -319,7 +320,8 @@ def model_load_progress(
)
try:
yield tracker_context
with force_offline_if_cached(is_cached, model_name):
yield tracker_context
except Exception as e:
# Report error to both managers
progress_manager.mark_error(model_name, str(e))