opencode-plugin-litellm 1.4.2 → 1.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/plugin/v2.ts +6 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "opencode-plugin-litellm",
|
|
4
|
-
"version": "1.4.
|
|
4
|
+
"version": "1.4.3",
|
|
5
5
|
"description": "OpenCode CLI (v1 and v2) and Desktop plugin for LiteLLM proxy support with auto-detection and dynamic model discovery",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./src/index.ts",
|
package/src/plugin/v2.ts
CHANGED
|
@@ -487,6 +487,12 @@ async function reconcileProviderSources(
|
|
|
487
487
|
const definition = Plugin.define({
|
|
488
488
|
id: 'opencode-litellm',
|
|
489
489
|
async setup(context) {
|
|
490
|
+
// OpenCode 1.18.x embeds a v2 plugin host whose context has no `provider`
|
|
491
|
+
// domain. It still calls `setup` on any plugin that exports one, but those
|
|
492
|
+
// versions are served by the `server()` entrypoint below. Bail out before
|
|
493
|
+
// touching the logger so `server()`'s client-backed logging stays intact.
|
|
494
|
+
if (!context.provider) return
|
|
495
|
+
|
|
490
496
|
initV2Logging()
|
|
491
497
|
|
|
492
498
|
const pluginOptions = asRecord(context.options)
|