Repository navigation
Description
The problem
When a hook fails, the "Commit failed" dialog shows the hook's output. If that output contains an OSC 8 hyperlink, the linked text is shown with a dashed underline, which becomes solid on hover.
Clicking it shows a confirmation dialog with Cancel and OK buttons:
Do you want to navigate to https://example.com?
WARNING: This link could potentially be dangerous
Pressing OK closes the dialog, but the URL does not open, either in GitHub Desktop or in the default browser.
Release version
Version 3.6.11 (arm64)
Operating system
macOS 27.2.1 (26B131)
Steps to reproduce the behavior
-
In a terminal, create a repository with a failing pre-commit hook:
mkdir github-desktop-issue-23211 cd github-desktop-issue-23211 git init echo test > file.txt
-
Create
.git/hooks/pre-commitwith this content and make it executable:touch .git/hooks/pre-commit chmod +x .git/hooks/pre-commit
#!/usr/bin/env bash printf '\033]8;;https://example.com\a%s\033]8;;\a\n' 'Click me' exit 1
-
In GitHub Desktop, add the repository (File > Add Local Repository).
-
Select
file.txtand commit it. -
In the "Commit failed" dialog, click the underlined "Click me" text.
-
In the confirmation dialog, press OK.
Result: nothing opens.
Log files
2026-11-19T19:30:59.136Z - info: [ui] [AppStore] loading 5 repositories from store
2026-11-19T19:30:59.137Z - info: [ui] [AppStore] found account: navtoj (Navtoj Chahal)
2026-11-19T19:30:59.147Z - info: [ui] Subscribed 'navtoj' to Alive channel
2026-11-19T19:30:59.544Z - info: [ui] launching: 3.6.11 (Mac OS 27.2.1)
2026-11-19T19:30:59.544Z - info: [ui] execPath: '/Applications/GitHub Desktop.app/Contents/Frameworks/GitHub Desktop Helper (Renderer).app/Contents/MacOS/GitHub Desktop Helper (Renderer)'
2026-11-19T19:31:03.557Z - error: [ui] `git commit -F -` exited with an unexpected code: 1.
�]8;;https://example.com�Click me�]8;;�
2026-11-19T19:31:03.557Z - info: [ui] [Timing] Action 'create commit' for 'github-desktop-issue-23211' took 0.034s
2026-11-19T19:31:23.989Z - warn: [main] Prevented new window to: about:blank
Screenshots
Additional context
The escape sequence is the standard OSC 8 format:
ESC ] 8 ; ; URL BEL text ESC ] 8 ; ; BEL
Using the ST terminator (ESC \) instead of BEL gives the same result.
Activity
desktop-triage commentedon Nov 19, 2026
Triage: this reproduces a real bug in the embedded terminal's handling of OSC 8 hyperlinks, not a configuration or environment issue — classifying as bug (
HIGHconfidence), priority-3 (MEDIUMconfidence, since a workaround — opening the URL manually — exists and affects a narrow scenario). No duplicate issues were found after searching for related terminology (OSC 8, hyperlinks, commit-failed dialog links); the closest related issue, #21785 ("unable to copy text from 'Commit failed' modal"), addresses a different problem (clipboard copy) in the same dialog.Initial hypothesis
GitHub Desktop renders hook/git output in an
@xterm/xtermTerminalinstance without configuring a customlinkHandleroption. xterm.js detects OSC 8 hyperlinks itself (OscLinkProvider), and when nolinkHandleris supplied it falls back to its built-indefaultActivate, which callsconfirm(...)with exactly the "Do you want to navigate to ... WARNING: This link could potentially be dangerous" text seen in the report, and onOKcallswindow.open()then setsnewWindow.location.hrefto the URL. GitHub Desktop's main process registers a blanketcontents.setWindowOpenHandlerinmain.tsthat denies every new window and logsPrevented new window to: <url>— matching thePrevented new window to: (redacted) line in the attached log right after the OK click. Becausewindow.open()returns a window whose navigation is then blocked, the link silently fails to open. The fix would involve supplying a customlinkHandler.activateto theTerminalcomponent that opens the URL viashell.openExternal(asLinkButton` already does) instead of relying on xterm.js's browser-oriented default.