Skip to content

fix(provider): retain Zen discovery transport metadata - #47224

Open
kabishou11 wants to merge 3 commits into
anomalyco:devfrom
kabishou11:cursor/zen-discovery-ae90
Open

fix(provider): retain Zen discovery transport metadata#47224
kabishou11 wants to merge 3 commits into
anomalyco:devfrom
kabishou11:cursor/zen-discovery-ae90

Conversation

@kabishou11

@kabishou11 kabishou11 commented Sep 4, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #47120

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Zen authenticated model discovery was merging endpoint-only IDs into empty provider.opencode.models entries. That dropped per-model SDK/transport metadata, so Responses models like muse-spark fell back to the openai-compatible chat path and failed as opaque UnknownError.

This keeps discovery metadata so a model returned by authenticated Zen /v1/models stays on the right transport without a hand-written models map.

How did you verify your code works?

In packages/opencode:

  • bun typecheck
  • bun test test/provider/zen-models.test.ts test/provider/provider.test.ts (111 pass)

Screenshots / recordings

N/A - provider/catalog path, no UI change.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

kabishou11 and others added 2 commits September 4, 2026 05:37
Keep authenticated Zen /v1/models discoveries from collapsing into empty
provider.models entries that drop per-model SDK/transport metadata.

Co-authored-by: Zhu Lei <kabishou11@users.noreply.github.com>
@github-actions github-actions Bot added needs:compliance This means the issue will auto-close after 2 hours. and removed needs:compliance This means the issue will auto-close after 2 hours. labels Sep 4, 2026
@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Zen lists muse-spark-1.3-contributor-free, but OpenCode 1.18.27 omits it and invocation returns UnknownError

1 participant