fix: Error matching built-in providers if specified by name rather than inferred from model.#331
fix: Error matching built-in providers if specified by name rather than inferred from model.#331telackey wants to merge 5 commits intogoogle:mainfrom
Conversation
…ather than inferred by model.
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
|
No linked issues found. Please link an issue in your pull request description or title. Per our Contributing Guidelines, all PRs must:
You can also use cross-repo references like |
|
I think we have enough votes. How do I trigger re-running the community support action? |
|
bump |
|
Your branch is 1 commits behind git fetch origin main
git merge origin/main
git pushNote: Enable "Allow edits by maintainers" to allow automatic updates. |
|
Updated. |
Fixes #335
Description
This fixes an error where specifying a built-in provider by name when using ModelConfig would fail, because
router.resolve_provider(config.provider)without first callingproviders.load_builtins_once(), which was only called when the provider was being inferred.The actual fix here is tiny, which is to lift the load_builtins_once/load_plugins_once calls outside the if/then. Since the loading is done only once, the impact should be insignificant.
Before:
How Has This Been Tested?
Manually and new unit test added.
Checklist: