Skip to content

Bump gh copilot telemetry sampling to 100%#13362

Merged
williammartin merged 1 commit into
trunkfrom
wm-copilot-sampling-100
May 7, 2026
Merged

Bump gh copilot telemetry sampling to 100%#13362
williammartin merged 1 commit into
trunkfrom
wm-copilot-sampling-100

Conversation

@williammartin

@williammartin williammartin commented May 7, 2026

Copy link
Copy Markdown
Member

Description

Fixes https://github.com/github/cli/issues/1163

Bumps the telemetry sampling rate for the gh copilot command from 1% to 100%, to allow for better analysis of usage.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 7, 2026 15:32
@williammartin williammartin requested a review from a team as a code owner May 7, 2026 15:32
@williammartin williammartin requested a review from babakks May 7, 2026 15:32

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR increases telemetry sampling for the gh copilot command from 1% to 100% so usage metrics are no longer extrapolated from a small sample, aligning with the approach used for gh skill.

Changes:

  • Inject the telemetry CommandRecorder into gh copilot command construction.
  • Set the telemetry sample rate to SAMPLE_ALL (100%) when gh copilot runs.
  • Update copilot command tests and add coverage asserting the 100% sampling behavior.
Show a summary per file
File Description
pkg/cmd/root/root.go Passes the root telemetry recorder into NewCmdCopilot so the command can adjust sampling.
pkg/cmd/copilot/copilot.go Accepts a telemetry recorder and sets sample rate to 100% at command execution start.
pkg/cmd/copilot/copilot_test.go Updates constructor usage in tests and adds a test asserting sample rate is set to SAMPLE_ALL.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 3/3 changed files
  • Comments generated: 0

@williammartin williammartin merged commit 6176c3e into trunk May 7, 2026
29 checks passed
@williammartin williammartin deleted the wm-copilot-sampling-100 branch May 7, 2026 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants