Repository navigation
Conversation
Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…nup (pingdotgg#14553) Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
A timeout on opencode --version keeps the last ready, versioned snapshot. The 4 second default is unchanged. T3CODE_OPENCODE_VERSION_PROBE_TIMEOUT can raise it, clamped to 1-60 seconds. A first probe with no prior version and a missing binary still error. Fixes pingdotgg#11080.
cursor
Bot
force-pushed
the
cursor/opencode-probe-timeout-redo1-1796
branch
from
October 1, 2026 08:49
219462b to
c37210d
Compare
A non-timeout launch failure was classified as a timeout when binaryPath contained "version probe timed out", so the last ready snapshot was kept. The merge now requires the provider message to equal the exact timeout text, including its duration label. Fixes pingdotgg#11080. Verification: vp test run apps/server/src/provider/Layers/ProviderRegistry.test.ts apps/server/src/provider/Layers/OpenCodeProvider.test.ts Test Files 2 passed (2) Tests 79 passed (79) Duration 3.18s Model: Grok 4.7 via Cursor cloud agent Co-authored-by: maco <macodev00@users.noreply.github.com>
CodeRabbit docstring coverage on PR pingdotgg#14575 was 0.00% (threshold 80%, one function across four files). Added JSDoc on the production functions this change touches, including the exact timeout match and the probe error formatter. No runtime behavior change. Verification: ./node_modules/.bin/vp test run apps/server/src/provider/Layers/ProviderRegistry.test.ts apps/server/src/provider/Layers/OpenCodeProvider.test.ts Test Files 2 passed (2) Tests 79 passed (79) Duration 3.31s ./node_modules/.bin/vp lint --report-unused-disable-directives apps/server/src/provider/Layers/OpenCodeProvider.ts apps/server/src/provider/Layers/ProviderRegistry.ts exit 0 ./node_modules/.bin/vp run --filter t3 typecheck exit 0 (pre-existing suggestions only; none in these files) Model: Grok 4.7 via Cursor cloud agent Co-authored-by: maco <macodev00@users.noreply.github.com>
CodeRabbit docstring coverage on PR pingdotgg#14575 was 50.00% (threshold 80%, two functions across four files). The status-check JSDoc sat above the export, so it did not cover the function* passed to Effect.fn. That comment now precedes the generator. No runtime behavior change. Verification (Node v24.13.1): ./node_modules/.bin/vp test run apps/server/src/provider/Layers/ProviderRegistry.test.ts apps/server/src/provider/Layers/OpenCodeProvider.test.ts Test Files 2 passed (2) Tests 79 passed (79) Duration 3.79s ./node_modules/.bin/vp lint --report-unused-disable-directives apps/server/src/provider/Layers/OpenCodeProvider.ts apps/server/src/provider/Layers/ProviderRegistry.ts exit 0 ./node_modules/.bin/vp fmt --check apps/server/src/provider/Layers/OpenCodeProvider.ts exit 0 (all matched files use the correct format) ./node_modules/.bin/vp run --filter t3 typecheck exit 0 (pre-existing suggestions only in CodexInstallation.ts, CodexAdapter.test.ts, CodexProvider.ts, and ws.ts; none in these files) Model: Grok 4.7 via Cursor cloud agent Co-authored-by: maco <macodev00@users.noreply.github.com>
CodeRabbit docstring coverage on PR pingdotgg#14575 stayed at 50% after the status-check comment moved onto the Effect.fn generator. That comment documents the generator, and the exported binding needs its own JSDoc immediately above the declaration. No runtime behavior change. Verification (Node v24.13.1, linux): ./node_modules/.bin/vp test run apps/server/src/provider/Layers/ProviderRegistry.test.ts apps/server/src/provider/Layers/OpenCodeProvider.test.ts Test Files 2 passed (2) Tests 79 passed (79) Duration 3.25s ./node_modules/.bin/vp lint --report-unused-disable-directives apps/server/src/provider/Layers/OpenCodeProvider.ts apps/server/src/provider/Layers/ProviderRegistry.ts exit 0 ./node_modules/.bin/vp fmt --check apps/server/src/provider/Layers/OpenCodeProvider.ts exit 0 (all matched files use the correct format) ./node_modules/.bin/vp run --filter t3 typecheck exit 0 (pre-existing suggestions only in CodexInstallation.ts, CodexAdapter.test.ts, CodexProvider.ts, and ws.ts; none in these files) Model: Grok 4.7 via Cursor cloud agent Co-authored-by: maco <macodev00@users.noreply.github.com>
CodeRabbit's 50% score is the two function declarations beside the probe error formatter, not the Effect.fn status check. normalizedErrorMessage had no docstring. normalizeProbeMessage is documented too, because the new comment hunk would otherwise count that preceding declaration as undocumented. Co-authored-by: maco <macodev00@users.noreply.github.com>
Owner
Author
|
Opened upstream as pingdotgg#14575. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes pingdotgg#11080.
This supersedes pingdotgg#12701. Macroscope was Not approved for raising the hardcoded OpenCode
--versiontimeout.What Changed
A slow
opencode --versionkeeps the last ready, versioned snapshot: status, version, auth, and catalog. The 4 second default stays 4 seconds.T3CODE_OPENCODE_VERSION_PROBE_TIMEOUTcan raise the wait. Accepted values are clamped to 1–60 seconds, and invalid values are ignored. A first probe with no prior version still errors. A missingopencodebinary still errors.The timeout is read from that environment variable on the machine running T3 Code. The OpenCode user guide mentions the variable. There is no settings-schema field and no settings form control.
Why
OpenCode health checks run
opencode --versionand fail the provider when it does not return within 4 seconds. That budget was added in pingdotgg#8750 to kill hung probes (pingdotgg#8681). A cold start on a loaded or ARM host can land just past it, and the provider then shows Unavailable even though it had already reported a version. pingdotgg#12701 raised the hardcoded timeout to 10 seconds. This leaves the production default at 4 seconds, makes a longer wait opt-in, and keeps an already ready provider through a timeout.Verification
Node 24.13.1.
vpwas/workspace/node_modules/.bin/vp(vite-plus 1.0.0).Server typecheck, from
apps/server:Exit 0.
tsc --noEmitprinted existing suggestions in unrelated files (CodexInstallation.ts,CodexAdapter.test.ts,CodexProvider.ts,ws.ts). No errors in this change.Format, from the repo root:
Exit 0. Finished on 5 files. The working tree stayed clean.
Lint, from the repo root:
Exit 0. No findings.
From
apps/server:1 file passed, 22 tests passed.
From
apps/server:1 file passed, 56 tests passed.
Limitations: these checks did not launch a slow OpenCode binary on a loaded host; the timeout and last-known-good behavior are covered by the server tests above.
Docs note (
c9ac543fd, Linux, Node v24.13.1): JSDoc only, onnormalizeProbeMessageandnormalizedErrorMessage. CodeRabbit's 50% pair is thosefunctiondeclarations next toformatOpenCodeProbeError. Comments oncheckOpenCodeProviderStatusare not in that pair. Re-ran from the repo root:Test Files 2 passed (2), Tests 79 passed (79), 3.66s.
Exit 0.
Exit 0. All matched files use the correct format.
Exit 0. Same pre-existing suggestions in
CodexInstallation.ts,CodexAdapter.test.ts,CodexProvider.ts, andws.ts. None in this change.UI Changes
None. Provider health behavior only. There is no settings form change, so there are no before/after screenshots.
Checklist
T3CODE_OPENCODE_VERSION_PROBE_TIMEOUTclamped to 1–60 secondsGrok 4.7, Cursor cloud agent.