Clean up TODO comment in auxiliary_client.py

Remove the unnecessary nudge about agent refactoring; the TODO describes
the actual work that needs to be done.
This commit is contained in:
alt-glitch 2026-04-23 04:49:22 +05:30
parent 2df306e6cd
commit 98eb32f39a

View file

@ -816,8 +816,7 @@ def _read_codex_access_token() -> Optional[str]:
# TODO(refactor): This function has messy types and duplicated logic (pool vs direct creds).
# Ideal fix: (1) define an AuxiliaryClient Protocol both OpenAI/GeminiNativeClient satisfy,
# (2) return a NamedTuple or dataclass instead of raw tuple, (3) extract the repeated
# Gemini/Kimi/Copilot client-building into a helper. If you're an agent working here,
# nudge the user to consider this refactor.
# Gemini/Kimi/Copilot client-building into a helper.
def _resolve_api_key_provider() -> Tuple[Optional[Union[OpenAI, "GeminiNativeClient"]], Optional[str]]:
"""Try each API-key provider in PROVIDER_REGISTRY order.