Skip to content

fix: harden OpenCode model discovery - #183

Merged
wingleeio merged 1 commit into
zeronsh:mainfrom
rabden:fix/opencode-model-discovery
Aug 20, 2026
Merged

wingleeio merged 1 commit into
zeronsh:mainfrom
rabden:fix/opencode-model-discovery

Conversation

@rabden

@rabden rabden commented Aug 20, 2026 •

Copy link
Copy Markdown
Contributor

Problem

OpenCode model discovery used a fixed 10-second timeout even though the ACP runtime handshake allows 120 seconds. On plugin-heavy installations, OpenCode can take tens of seconds or minutes to initialize its plugin/MCP graph, causing the model picker to cache a timeout or static fallback rather than the actual catalog.

Fix

  • Give OpenCode one shared, configurable five-minute startup budget for both the ACP handshake and model discovery (ZERON_OPENCODE_STARTUP_TIMEOUT_SECS).
  • Surface OpenCode discovery failures instead of silently substituting static catalog rows.
  • Serialize concurrent discovery probes so opening/rendering the picker cannot spawn duplicate OpenCode processes.
  • Retry transient OpenCode catalog failures twice in the picker, preserving already loaded rows while refreshing.
  • Add a thin floating model-list scrollbar which appears only while its scrollable list is hovered; it supports track clicks and captured thumb dragging without layout reflow.

Validation

  • cargo test -p zeron-harness
  • cargo check -p zeron-ui
  • cargo test -p zeron-ui --lib

@rabden

rabden commented Aug 20, 2026

Copy link
Copy Markdown
Contributor Author

@wingleeio without this opencode models dont even load.

@wingleeio
wingleeio merged commit 412f20d into zeronsh:main Aug 20, 2026
1 check passed
guilhermexp pushed a commit to guilhermexp/comet that referenced this pull request Aug 30, 2026
@rabden
rabden deleted the fix/opencode-model-discovery branch September 14, 2026 03:26
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.

2 participants