Terminal/tab title degrades to a bare ";" after a while in a session (SecureCRT)
まだ誰も着手していません。
- 主要言語
- Shell
- スター
- 11.2k
- フォーク
- 1.9k
- 平均マージ
- 14時間 16分
- マージ済み PR(30日)
- 6
説明
Environment
- GitHub Copilot CLI version: 1.0.70 (native binary,
@github/copilot-linux-x64) - Installed via:
npm install -g @github/copilot - OS: Linux (server), accessed interactively through a SecureCRT SSH session (Windows client)
- Shell: bash
Summary
When starting a copilot session, the SecureCRT window title and tab label are
correctly set to "GitHub Copilot". At some point later in the same session
(observed while the CLI was in a "Working - plan" state, showing session
stats like "AIC used" and the active model name), the title degrades to a
single bare ; character — both in the OS-level window title bar and in the
SecureCRT tab label. It stays as ; afterward instead of showing anything
meaningful about the session.
This started happening recently — it was not observed before, and lines up
with upgrading from CLI v1.0.69 to v1.0.70 (released 2026-07-07 and
2026-07-10 respectively); a v1.0.71 pre-release was also published the same
day as v1.0.70. I have not confirmed which exact version introduced the
regression, but it is new behavior within roughly the last few days.
Screenshots
- Just after starting a session — title correctly shows "GitHub Copilot":
(attachjust-started-session.png) - Later in the same session (in "Working - plan" state) — title has
degraded to a bare;:
(attacheventual-state.png)
(Both screenshots are available locally; please attach them to this issue
when filing — image upload requires interactive drag-and-drop or the
GitHub web UI.)
Investigation done so far
I don't have access to the CLI's source (the npm package ships only a
compiled native binary per platform, invoked via npm-loader.js), so I
investigated empirically:
- Captured the raw bytes written to the terminal by
copilotv1.0.70 via a
PTY harness that also answers the CLI's startup terminal-capability
handshake (OSC 10/11 fg/bg color queries, OSC 4 palette queries, DECRQM
reports for modes 2026/12, and theCSI ?996ndark/light-mode query). - Confirmed the startup title write is a single, well-formed OSC 0 sequence:
ESC ] 0 ; GitHub Copilot BEL— clean and correctly terminated. This
matches screenshot 1 exactly. - Found (via this user's own
~/.copilot/logs/process-*.logfiles across
many past sessions) that the CLI has an automatic session-naming feature
that logs anINFO Session named: "<short descriptive title>"line,
firing once per session roughly 30–90 seconds into the first substantive
turn. This is almost certainly the mechanism that pushes a second title
update to the terminal after the initial static "GitHub Copilot" — and is
the most likely place where the corruption originates. - Was not able to capture the corrupted OSC payload live/byte-for-byte
within the time available in a scripted reproduction (the scripted nested
session did not reach the auto-naming point quickly enough in the test
sandbox), so this report is based on strong circumstantial evidence
rather than a captured raw byte dump of the bad sequence.
Root-cause hypothesis
The bare ; is much more consistent with a client-side (CLI) title-string
formatting bug than with a terminal-emulator-side (SecureCRT) parsing/
truncation problem:
- A torn/truncated OSC escape sequence reaching a terminal typically either
(a) fails to parse as a title update at all, and is instead printed as
literal garbage into the terminal grid (not the title bar), or (b) is
ignored, leaving the previous valid title in place. Neither matches what's
observed — the title bar is cleanly replaced by a single punctuation
character. - A single bare
;is exactly what you'd get from a title-string builder
that joins multiple segments (e.g. an icon/status segment and a
session-name segment) with";"as a separator, in a case where both
segments evaluate to an empty string (e.g., while in "Working"/plan-mode
status, or if the generated session name isn't available yet at the moment
of the title write).
Suggested fix direction
Filter out empty/falsy segments before joining them with ; (or whatever
separator is used) when composing the dynamic terminal title, so a title
update never results in just the bare separator character.
Steps to reproduce (best effort — timing-dependent)
- Start
copilotin an interactive terminal that supports OSC 0/2 title
sequences (e.g. SecureCRT with "allow remote title changes" or similar
enabled). - Confirm the window/tab title shows "GitHub Copilot".
- Send a normal chat message and let the session run for a minute or two,
into a "Working"/plan-mode state, long enough for the automatic
session-naming feature to trigger. - Observe the window/tab title — in the reported case it degrades to a bare
;instead of showing the auto-generated session name.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
npm-loader.js を介して呼び出されるネイティブバイナリと、レポートで説明されている PTY ハーネスから始めます。自動セッション命名に伴う OSC タイトル更新を再現し、プロセスログで “Session named” イベントを調べます。報告されている Working/plan 状態の間も含め、動的なタイトル更新によって意味のあるタイトルがセミコロンだけのタイトルに置き換えられなくなれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- shell
- 領域
- cli
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 静か
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100