fix(models): clear probe negative-cache entry on a successful probe

This commit is contained in:
kshitijk4poor
2026-09-09 18:24:17 +05:30
committed by kshitij
parent 48b8528e7c
commit 4e2a871adb
+2
View File
@@ -2256,6 +2256,8 @@ def probe_api_models(
data = _get_json(url, timeout=timeout, headers=headers, **_open_kwargs)
except Exception:
continue
if _neg_key is not None:
_probe_neg_cache.pop(_neg_key, None)
return _probe_result(
[m.get("id", "") for m in data.get("data", [])], url, candidate_base.rstrip("/"),
alternate_base if alternate_base != candidate_base else normalized, is_fallback)