Commit 040f798
Fix empty provider causing wiki generation failure
When navigating to a repo URL without a ?provider= param, the provider
state initialized as '' (empty string). The async fetch to resolve the
default provider from /api/models/config hadn't completed before wiki
generation started, sending provider='' to the backend. Pydantic accepted
the empty string (not triggering the "google" default), causing
"Configuration for provider '' not found" errors.
Fixes:
- Backend: fall back to configured default_provider when provider is empty
- Frontend: synchronously resolve provider before starting generation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent cc12c30 commit 040f798
2 files changed
Lines changed: 27 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
141 | 149 | | |
142 | 150 | | |
143 | 151 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
435 | 435 | | |
436 | 436 | | |
437 | 437 | | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
438 | 456 | | |
439 | 457 | | |
440 | 458 | | |
| |||
580 | 598 | | |
581 | 599 | | |
582 | 600 | | |
583 | | - | |
| 601 | + | |
584 | 602 | | |
585 | 603 | | |
586 | 604 | | |
| |||
0 commit comments