Conversation
Cold wrappers and loaded hosts can take more than 4s for `opencode --version`, which flipped a working provider to Unavailable. Raise the probe budget to 10s and keep the last ready version/status through a single timeout. Hung probes are still process-group killed at the cap. Fixes pingdotgg#11080
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: pingdotgg/t3code/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 10 included reviews per hour; 6 remain after this review. 📝 WalkthroughWalkthroughThe OpenCode version probe timeout increases from 4 to 10 seconds. Tests cover delayed probes and hanging probes. Provider snapshot merging preserves ready, versioned OpenCode state after a version-probe timeout. ChangesOpenCode version probe timeout handling
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Bug fix · Severity of issue fixed: Low Sequence Diagram(s)sequenceDiagram
participant OpenCodeProvider
participant ProviderRegistry
participant OpenCodeCLI
OpenCodeProvider->>OpenCodeCLI: Run --version
OpenCodeCLI-->>OpenCodeProvider: Return version or exceed probe timeout
OpenCodeProvider->>ProviderRegistry: Submit provider snapshot
ProviderRegistry-->>OpenCodeProvider: Preserve eligible last-known-good state
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
@coderabbitai review |
|
|
@coderabbitai review |
|
What Changed
Raise OpenCode CLI version-probe timeout from 4s to 10s (
OPENCODE_VERSION_PROBE_TIMEOUTinOpenCodeProvider.ts). Process-group kill on timeout is unchanged.In
mergeProviderSnapshot: if a probe times out after a ready, versioned snapshot, keep that version/auth/ready status (plus cached models/skills) instead of flipping to error. First-boot timeouts with no prior version still error. Missing binary / inventory failures still error.Fixes #11080
Why
The 4s budget was added for hung wrappers (#8750), not slow-but-healthy OpenCode startups (e.g. ARM under load). A single timeout was clearing ready status and making the provider look Unavailable.
UI Changes
No UI change. Provider health behavior only. Screenshots/video not applicable.
Checklist
Summary by CodeRabbit