fix(router): widen _remove_deployment_from_wildcard_state to Optional[str]

Moving the call out of the inner `deployment_id in deployment_fast_mapping`
block in the previous commit lost mypy's narrowing of `deployment_id`
from Optional[str] to str, tripping the lint CI. The helper already
handles None via its falsy guard, so widening the annotation matches
the actual contract.
This commit is contained in:
Aarkin7 2026-06-04 21:34:40 +05:30
parent 171def59df
commit 0f241a28c4

View file

@ -8733,7 +8733,7 @@ class Router:
except Exception:
return None
def _remove_deployment_from_wildcard_state(self, model_id: str) -> None:
def _remove_deployment_from_wildcard_state(self, model_id: Optional[str]) -> None:
"""
Drop every reference to model_id from the wildcard-routing data
structures. Without this, upsert/delete leaves stale credentials in