Log when shell type changes for ai clis#309688
Merged
anthonykim1 merged 4 commits intomainfrom Apr 14, 2026
Merged
Conversation
Contributor
Author
|
/cc @meganrogge |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds additional terminal telemetry to better understand runtime shell type detection, particularly for agentic CLIs whose identification can change after startup.
Changes:
- Log a new telemetry event (
terminal/shellTypeChanged) whenever a terminal instance’s detectedshellTypechanges. - Prefer
instance.shellTypewhen emittingterminal/createInstancetelemetry (fallback togetSanitizedShellType). - Extend the terminal telemetry shell type allowlist with AI CLI entries (claude/codex/copilot/gemini).
Show a summary per file
| File | Description |
|---|---|
| src/vs/workbench/contrib/terminal/browser/terminalTelemetry.ts | Adds shell-type-changed telemetry and adjusts shell type value selection/allowlist for terminal telemetry events. |
Copilot's findings
Comments suppressed due to low confidence (1)
src/vs/workbench/contrib/terminal/browser/terminalTelemetry.ts:152
- For the new
terminal/shellTypeChangedevent, the loggedshellTypeis currently the rawTerminalShellTypestring. If this is intended to align with the existingterminal/createInstanceshellTypetaxonomy in this file, it should be normalized/sanitized the same way (eg mapgitbash->git-bash) to avoid splitting telemetry across multiple spellings for the same shell.
this._telemetryService.publicLog2<TerminalShellTypeChangedTelemetryData, TerminalShellTypeChangedTelemetryClassification>('terminal/shellTypeChanged', {
shellType: new TelemetryTrustedValue(instance.shellType ?? 'unknown'),
terminalSessionId: instance.sessionId,
- Files reviewed: 1/1 changed files
- Comments generated: 1
Contributor
joshspicer
approved these changes
Apr 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Coming from: #290830
and #304528