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
On Windows, every gh aw invocation — including no-op commands like gh aw version
and gh aw --help — hangs indefinitely at startup, producing zero output, when run
inside a ConPTY-based pseudo-terminal (specifically the Cursor IDE integrated
terminal). The same binary works fine in a normal console (Windows Terminal /
standalone PowerShell / cmd).
This looks like the same startup terminal-capability probe addressed in
PR #37823 ("Guard startup terminal probing on Windows when stderr is redirected"),
but that guard does not cover this case: the guard skips probing only when stderr
is redirected (pipe/file, e.g. CI). Under a live ConPTY the std handles look
like a real console character device, so the guard enables the probe, and the
probe then blocks waiting for a terminal query response that the pseudo-console
never returns.
Environment
OS: Windows 10 (10.0.19045)
gh: 2.95.0
gh aw: github/gh-aw v0.80.9 (latest release as of 2026-06-22)
Host terminal: Cursor IDE integrated terminal (PowerShell over Windows ConPTY)
Install: clean gh extension install github/gh-aw; on disk gh-aw.exe +
manifest.yml + state.yml all present and intact.
Steps to reproduce
On Windows, install the extension: gh extension install github/gh-aw.
From a ConPTY-based pseudo-terminal (e.g. the Cursor IDE integrated terminal),
run: gh aw version
Observe: it hangs forever with no output. gh aw --help behaves the same.
Expected
gh aw version prints gh aw version v0.80.9 and exits promptly, as it does in a
real console.
Actual
Hangs at startup, before any output, on non-interactive commands. Must be killed.
Evidence / what I ruled out
Not a corrupt install — gh extension list shows v0.80.9; binary + manifest
state.yml are all intact. Reinstalling does not help.
Not a network / auto-upgrade stall — state.yml shows the update check already
completed and the extension is current; gh auth status reaches GitHub fine.
Reproduces with full redirection — running gh-aw.exe directly with
stdin/stdout/stderr all redirected to files STILL hangs. (This is the key signal
that the Guard startup terminal probing on Windows when stderr is redirected #37823 stderr guard is insufficient: even with stderr redirected to a
file, it hangs — suggesting the probe opens the console device directly rather
than going through the redirected stderr handle.)
Works in a real console — launching the exact same binary in a freshly
allocated (hidden) conhost console completes immediately and prints the version.
Only the terminal environment differs.
Env-var bypass attempts don't help — CI=true, NO_COLOR=1, TERM=dumb all still
hang, consistent with the probe querying the console device directly.
Suspected root cause
The Windows guard added in PR #37823 (shouldConfigureLipglossCompat / configureLipglossCompat in pkg/styles/theme.go) gates the probe on whether stderr is a console character device. That correctly skips probing when stderr
is redirected (CI/pipe), but:
Under a live ConPTY the handle still presents as a console char device, so the
guard ENABLES the probe; and
the hang reproduces even when stderr IS redirected to a file, which implies the
probe reaches the console device directly rather than honoring the stderr handle.
Net effect: the merged fix targets "stderr redirected" but not "interactive
pseudo-console that never answers the capability query" (Cursor's ConPTY).
Suggested directions (for maintainers)
Make the terminal-capability probe time-bounded / cancellable so an unanswered
query can't block startup indefinitely.
Provide an explicit opt-out env var (e.g. GH_AW_NO_TERMINAL_PROBE=1) that fully
disables the probe regardless of detected device type.
Re-examine whether the probe queries CONOUT$/CONIN$ directly; if so, the
stderr-only guard cannot prevent this class of hang.
Workaround (for other users hitting this)
Run gh aw from an external console, or wrap it so it spawns in its own console:
spawn gh aw in a fresh hidden console and capture output back
Start-Process cmd -ArgumentList '/c','gh aw version 1>out.txt 2>&1' -WindowStyle Hidden -Wait
Get-Content out.txt
Summary
On Windows, every
gh awinvocation — including no-op commands likegh aw versionand
gh aw --help— hangs indefinitely at startup, producing zero output, when runinside a ConPTY-based pseudo-terminal (specifically the Cursor IDE integrated
terminal). The same binary works fine in a normal console (Windows Terminal /
standalone PowerShell / cmd).
This looks like the same startup terminal-capability probe addressed in
PR #37823 ("Guard startup terminal probing on Windows when stderr is redirected"),
but that guard does not cover this case: the guard skips probing only when stderr
is redirected (pipe/file, e.g. CI). Under a live ConPTY the std handles look
like a real console character device, so the guard enables the probe, and the
probe then blocks waiting for a terminal query response that the pseudo-console
never returns.
Environment
gh extension install github/gh-aw; on disk gh-aw.exe +manifest.yml + state.yml all present and intact.
Steps to reproduce
gh extension install github/gh-aw.run:
gh aw versiongh aw --helpbehaves the same.Expected
gh aw versionprintsgh aw version v0.80.9and exits promptly, as it does in areal console.
Actual
Hangs at startup, before any output, on non-interactive commands. Must be killed.
Evidence / what I ruled out
gh extension listshows v0.80.9; binary + manifestcompleted and the extension is current;
gh auth statusreaches GitHub fine.stdin/stdout/stderr all redirected to files STILL hangs. (This is the key signal
that the Guard startup terminal probing on Windows when stderr is redirected #37823 stderr guard is insufficient: even with stderr redirected to a
file, it hangs — suggesting the probe opens the console device directly rather
than going through the redirected stderr handle.)
allocated (hidden) conhost console completes immediately and prints the version.
Only the terminal environment differs.
hang, consistent with the probe querying the console device directly.
Suspected root cause
The Windows guard added in PR #37823 (
shouldConfigureLipglossCompat/configureLipglossCompatinpkg/styles/theme.go) gates the probe on whetherstderr is a console character device. That correctly skips probing when stderr
is redirected (CI/pipe), but:
guard ENABLES the probe; and
probe reaches the console device directly rather than honoring the stderr handle.
Net effect: the merged fix targets "stderr redirected" but not "interactive
pseudo-console that never answers the capability query" (Cursor's ConPTY).
Suggested directions (for maintainers)
query can't block startup indefinitely.
GH_AW_NO_TERMINAL_PROBE=1) that fullydisables the probe regardless of detected device type.
stderr-only guard cannot prevent this class of hang.
Workaround (for other users hitting this)
Run
gh awfrom an external console, or wrap it so it spawns in its own console:spawn gh aw in a fresh hidden console and capture output back
Start-Process cmd -ArgumentList '/c','gh aw version 1>out.txt 2>&1' -WindowStyle Hidden -Wait
Get-Content out.txt