Skip to content

Desktop: Vertex Anthropic models resolve to wrong region + invalid @default version in new worktrees #32550

Description

@lenrt

Description

In opencode Desktop, the model selection dropdown shows a different (incorrect) set of Vertex Anthropic models in newly created git worktrees compared to existing/older worktrees of the same project.

In older worktrees, the dropdown correctly lists region-appropriate Vertex Anthropic models (e.g. Claude 4.7 Opus under "Vertex Anthropic (EU Multi-Region)" and Claude Sonnet 4.6 under "Vertex Anthropic (europe-west1)").
In newly created worktrees, the dropdown instead lists models that are not configured the same way (e.g. Claude Opus 4.8 and Claude Sonnet 4.6 under a generic "Vertex (Anthropic)" group), and selecting them fails.

When Claude Opus 4.8 is selected in a new worktree, the request fails with:
Publisher Model projects/devtools-288204/locations/europe-west1/publishers/anthropic/models/claude-opus-4-8@default was not found or your project does not have access to it. Please ensure you are using a valid model version.
Two things appear wrong in this resolved model path:

An invalid version suffix @default is appended to the model ID. Vertex expects either a concrete version or no suffix; @default is not a valid Vertex model-version identifier.
The model is resolved against the regional endpoint locations/europe-west1, where this model is not available for the project, instead of the multi-region / correct endpoint used successfully in the older worktree.

Plugins

none

OpenCode version

v1.17.7

Steps to reproduce

  1. Have a project configured with Vertex Anthropic models via ADC (gcloud auth application-default login), using EU endpoints (EU Multi-Region + europe-west1).
  2. Open an existing/older worktree → model dropdown shows correct models, selection works.
  3. Create a new git worktree of the same project and open it in opencode Desktop.
  4. Open the model dropdown → observe a different model set.
  5. Select a Vertex Anthropic model → request fails with the @default / wrong-region error above.

Screenshot and/or share link

Image Image

Operating System

No response

Terminal

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions