You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
Make the name gh resolve on the server's PATH to a wrapper script that is slower than 5s, rather than to the real binary. Version managers do this routinely. A minimal stand-in:
# ~/.local/bin/gh, earlier on PATH than the real binary#!/bin/bash
sleep 10
exec /path/to/real/gh "$@"
Confirm the CLI itself is healthy and authenticated by calling the real binary directly.
Open Settings → Source Control and choose Rescan server environment.
Expected behavior
Either GitHub is reported as available, or the row explains that the probe timed out — something that points at the real problem.
Actual behavior
GitHub is reported as:
Not available on this server: Install the GitHub command-line tool (gh) via https://cli.github.com/ or your package manager.
The CLI is installed, on PATH, and authenticated. The message is actively misleading: it tells the user to install software they already have, and it names PATH as the cause when PATH resolution succeeded.
The mechanism is in SourceControlProviderDiscovery.ts. probeCli runs <executable> --version with DEFAULT_PROBE_TIMEOUT_MS = 5_000 and maps any failure to status: "missing". probeSourceControlProvider then discards the captured cause and substitutes a fixed string:
auth: unknownAuth("Hosting integration command was not found on the server PATH.")
So a timeout, a non-zero exit, and a genuine ENOENT are all reported to the user as "not found on PATH". The same 5s budget applies to glab and az; az already carries probeTimeoutMs: 20_000 with a comment noting that "gh and glab answer in ~0.3s" — an assumption that holds for the real binaries but not for wrappers in front of them.
# The real binary is fine:
$ /home/user/.local/share/mise/installs/gh/latest/.../bin/gh --version
gh version 2.100.0 (2026-09-03) # 180ms# The name on PATH is not. Five consecutive runs, 30s timeout each:
$ foriin 1 2 3 4 5;do timeout 30 gh --version;echo"rc=$?";done
rc=124
rc=124
rc=124
rc=124
rc=124
# Left to run to completion, it never returns and burns CPU:
$ time gh --version
real 7m3.987s
user 3m44.518s
sys 4m16.829s
Related issues
[Bug]: macOS Source Control reports installed Homebrew gh as unavailable #7618 reports the same user-visible symptom on macOS, but through a different root cause: there the server's PATH genuinely lacks the CLI's directory (spawn gh ENOENT, Finder-launched .app with PATH=/usr/bin:/bin:/usr/sbin:/sbin). This report is the opposite case — PATH resolution succeeds and the probe times out on what it found. Both surface as the same "install gh" message, which is part of why the message is a problem.
Workaround
Ensure the name on PATH resolves to the real binary, by removing the wrapper or reordering PATH. There is currently no way to tell T3 Code which executable to use, so the only fix available to the user is to change their system.
Before submitting
Area
apps/server
Steps to reproduce
Make the name
ghresolve on the server'sPATHto a wrapper script that is slower than 5s, rather than to the real binary. Version managers do this routinely. A minimal stand-in:Confirm the CLI itself is healthy and authenticated by calling the real binary directly.
Open Settings → Source Control and choose Rescan server environment.
Expected behavior
Either GitHub is reported as available, or the row explains that the probe timed out — something that points at the real problem.
Actual behavior
GitHub is reported as:
The CLI is installed, on
PATH, and authenticated. The message is actively misleading: it tells the user to install software they already have, and it namesPATHas the cause whenPATHresolution succeeded.The mechanism is in
SourceControlProviderDiscovery.ts.probeCliruns<executable> --versionwithDEFAULT_PROBE_TIMEOUT_MS = 5_000and maps any failure tostatus: "missing".probeSourceControlProviderthen discards the captured cause and substitutes a fixed string:So a timeout, a non-zero exit, and a genuine
ENOENTare all reported to the user as "not found on PATH". The same 5s budget applies toglabandaz;azalready carriesprobeTimeoutMs: 20_000with a comment noting that "ghandglabanswer in ~0.3s" — an assumption that holds for the real binaries but not for wrappers in front of them.Impact
Major degradation or frequent failure
Version or commit
main @ 349ce30
Environment
mainLogs or stack traces
Related issues
PATHgenuinely lacks the CLI's directory (spawn gh ENOENT, Finder-launched.appwithPATH=/usr/bin:/bin:/usr/sbin:/sbin). This report is the opposite case —PATHresolution succeeds and the probe times out on what it found. Both surface as the same "installgh" message, which is part of why the message is a problem.Workaround
Ensure the name on
PATHresolves to the real binary, by removing the wrapper or reorderingPATH. There is currently no way to tell T3 Code which executable to use, so the only fix available to the user is to change their system.