get_available_models() references 'logger' in the except block of the custom endpoint fetch (added in PR #18), but 'logger' is never imported or defined in api/config.py. When the custom endpoint is unreachable (the normal case -- most users don't have a local LLM), the except handler raises NameError: name 'logger' is not defined, which propagates as a 500 on every GET /api/models request. This broke 7 test_sprint11 tests and caused the model dropdown to fail for all users regardless of whether they have a custom endpoint. Fix: replace logger.debug() with a silent pass -- the exception is expected when no local LLM is configured and needs no logging. Tests: 237 passed, 0 failed. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| config.py | ||
| helpers.py | ||
| models.py | ||
| routes.py | ||
| streaming.py | ||
| upload.py | ||
| workspace.py | ||