refactor: enhance error handling in user prompts

- Updated exception handling in multiple prompt functions to catch NotImplementedError alongside ImportError, improving robustness across the application.
- Ensured fallback mechanisms are clearly documented for better understanding of platform limitations.
This commit is contained in:
teknium1 2026-02-25 14:10:54 -08:00
parent cd66546e24
commit 3c5bf5b9d8
4 changed files with 8 additions and 8 deletions

View file

@ -923,7 +923,7 @@ def _prompt_model_selection(model_ids: List[str], current_model: str = "") -> Op
custom = input("Enter model name: ").strip()
return custom if custom else None
return None
except ImportError:
except (ImportError, NotImplementedError):
pass
# Fallback: numbered list