molecule-ai-workspace-templ.../tests
claude-ceo-assistant (Claude Opus 4.7 on Hongming's MacBook) a2c7bf3d3b fix(adapter): honor explicit provider config — fail fast when not in registry (#180)
Workspace operators set 'provider: minimax' in /configs/config.yaml
expecting the adapter to route to MiniMax. Pre-fix behavior: adapter
ignored 'provider:' entirely, _resolve_provider model-matched against
_BUILTIN_PROVIDERS (anthropic-oauth + anthropic-api only), no model_prefix
matched 'MiniMax-M2.7-highspeed', silent fallback to providers[0]
(anthropic-oauth) — SDK kept using CLAUDE_CODE_OAUTH_TOKEN, hit OAuth
quota under a name the operator never asked for.

Fix: _resolve_provider now takes an explicit_provider arg. setup() reads
it from runtime_config.provider OR top-level config.yaml provider:.
Explicit name in registry → returned. Not in registry → ValueError with
the two paths to fix (add provider entry, or switch runtime template).

10 new tests cover: explicit-in-registry returns match, case-insensitive,
not-in-registry raises with actionable message, defense-in-depth against
silent fallback regression, custom-registry lookup, empty/None treated as
no-explicit (back-compat).

Closes #180.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-07 10:58:51 -07:00
..
pytest.ini feat(adapter): pre-validate ANTHROPIC_BASE_URL + missing model combo 2026-04-30 22:35:49 -07:00
test_adapter_logging.py feat(adapter,entrypoint): boot env audit + crash-loop diagnosis logging 2026-05-02 21:41:05 -07:00
test_adapter_prevalidate.py fix(adapter): keep setup() routing — strip prefix only at CLI invocation 2026-05-01 16:46:54 -07:00
test_dev_channels_flag.py fix(executor): pass tagged server:molecule to dev-channels flag 2026-05-01 17:15:49 -07:00
test_provider_resolution.py fix(adapter): honor explicit provider config — fail fast when not in registry (#180) 2026-05-07 10:58:51 -07:00
test_provider_routing.py feat: per-vendor env routing for third-party providers (task #244) 2026-05-02 22:20:03 -07:00
test_runtime_wedge_mirror.py chore(executor): runtime_wedge mirror follow-ups from PR #29 review 2026-05-01 18:04:24 -07:00