Skip to content

Commit 2fdb3e2

Browse files
fix: backfill resolved_provider from model when inferred (#242)
When provider is inferred from the model (not passed explicitly), resolved_provider was None, causing ModalityClient.http_client to raise ClientNotFoundError for all modalities.
1 parent 6ebc51e commit 2fdb3e2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/celeste/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,9 @@ def create_client(
247247
protocol=resolved_protocol,
248248
)
249249

250+
if resolved_provider is None and resolved_protocol is None:
251+
resolved_provider = resolved_model.provider
252+
250253
# Client lookup: protocol takes precedence for compatible API path
251254
target = (
252255
resolved_protocol if resolved_protocol is not None else resolved_model.provider

0 commit comments

Comments
 (0)