Skip to content

fix(windows): suppress console flash in copilot_auth gh token lookup (#53370) - #53397

Closed
AlexFucuson9 wants to merge 1 commit into
NousResearch:mainfrom
AlexFucuson9:fix/windows-console-flash-copilot-auth
Closed

fix(windows): suppress console flash in copilot_auth gh token lookup (#53370)#53397
AlexFucuson9 wants to merge 1 commit into
NousResearch:mainfrom
AlexFucuson9:fix/windows-console-flash-copilot-auth

Conversation

@AlexFucuson9

Copy link
Copy Markdown
Contributor

Summary

_try_gh_cli_token() calls subprocess.run() without creationflags=windows_hide_flags(), so Windows spawns a visible console window for every gh.exe invocation. The credential pool polls this every ~15 seconds, causing repeated CMD window flashes.

This was missed in the May 16 flash-suppression pass (8bf0945) that fixed kanban_db.py, code_execution_tool.py, tools/local.py, and process_registry.py.

Fix

  • Import windows_hide_flags from hermes_cli._subprocess_compat
  • Add creationflags=windows_hide_flags() to the subprocess.run() call

Closes #53370

…ousResearch#53370)

_try_gh_cli_token() calls subprocess.run() without
creationflags=windows_hide_flags(), so Windows spawns a visible
console window for every gh.exe invocation. The credential pool
polls this every ~15 seconds, causing repeated CMD window flashes.

This was missed in the May 16 flash-suppression pass (8bf0945)
that fixed kanban_db.py, code_execution_tool.py, tools/local.py,
and process_registry.py.
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/cli CLI entry point, hermes_cli/, setup wizard platform/windows Native Windows-specific behavior or breakage sweeper:risk-platform-windows Sweeper risk: may break or behave differently on native Windows labels Jun 27, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

This was generated by AI during triage.

Competing/overlapping with open PRs #53390 and #53123 — all three patch the same _try_gh_cli_token() gh auth token spawn site (missing CREATE_NO_WINDOW). Related, not duplicate; maintainer should pick one. Same Windows console-flash family as merged #52340.

@tonydwb tonydwb left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review Summary

Verdict: Comment (competing fix)

This PR and #53390 are duplicate fixes for the same issue (suppress console flash in copilot_auth gh token lookup). Both add the identical 2-line change: import windows_hide_flags and pass it as creationflags. The changes are functionally identical.

Recommendation: Close one in favor of the other. Both are small, clean fixes. The author should coordinate to avoid merge conflicts.

Looks Good

  • Clean, focused fix
  • Uses the correct windows_hide_flags() utility
  • No security concerns

Reviewed by Hermes Agent

@teknium1

Copy link
Copy Markdown
Contributor

Closing as superseded by the consolidated Windows console-flash work tracked in #54220.

The relevant pieces from this PR/cluster have now landed through the targeted follow-up PRs #54236, #53892, and #54417, or are recorded in the umbrella tracker for any remaining native-Windows verification. Keeping this separate PR open would duplicate the tracker and the merged follow-up work.

Thanks for digging into this — the reports and PRs in this cluster helped identify the remaining spawn legs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists platform/windows Native Windows-specific behavior or breakage sweeper:risk-platform-windows Sweeper risk: may break or behave differently on native Windows type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(windows): suppress console window flash when spawning gh auth token

4 participants