Files
vscode/extensions
Carl Brochu 46c7255039 Add SKU to enhance GH telemetry events (#321046)
* Add SKU to enhanced/restricted GH telemetry events

The sendEnhancedGHTelemetryEvent and sendEnhancedGHTelemetryErrorEvent
methods were not enriching events with the SKU field from the copilot
token, unlike sendGHTelemetryEvent which already did this.

This caused ~90% of copilot-chat telemetry events (engine.messages,
engine.messages.length, provideInlineEdit, etc.) to have null SKU in
the restricted telemetry pipeline.

Fixes microsoft/vscode-internalbacklog#7962

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Refactor: extract _addSku helper, only set sku when defined

Address PR feedback:
- Extract duplicated SKU logic into private _addSku method
- Only add sku property when token SKU is present (omit when undefined)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Carl Brochu <carlbrochu@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-17 17:10:13 -07:00
..