Add GDPR declaration for pyrefly.detection telemetry event#26053
Merged
Conversation
The vscode-pylance PYREFLY.DETECTION event (sent as ms-python.python/pyrefly.detection) was shipping in Pylance 2026.2.109 / 2026.3.1 and firing on the same reporter as language_server.ready, but showed zero data in telemetry because the event name was not declared in this GDPR allow-list and was therefore scrubbed before ingestion. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: a93b6348-9ac6-4951-8998-8d607333b267
bschnurr
approved these changes
Jul 22, 2026
heejaechang
approved these changes
Jul 22, 2026
| "failed" : { "classification": "SystemMetaData", "purpose": "PerformanceAndHealth" } | ||
| } | ||
| */ | ||
| /** |
There was a problem hiding this comment.
Do the gdpr items not need to be on the python extension side anymore? I have the impression that we always added there.
There was a problem hiding this comment.
my bad, just realized it's the python extension
Author
There was a problem hiding this comment.
THey're on both apparently. I wish we could move them to just inside of PYlance
StellaHuang95
approved these changes
Jul 22, 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.
Summary
Adds a
__GDPR__declaration for the Pylancepyrefly.detectiontelemetry event so it is allow-listed and reaches the telemetry pipeline.Background
Pylance emits a
PYREFLY.DETECTIONevent (sent through thems-python.pythonreporter asms-python.python/pyrefly.detection) during background Pyrefly detection, to measure the addressable audience that could be offered a switch to Pyrefly. The event shipped in Pylance2026.2.109(pre-release) and2026.3.1(stable) and fires unconditionally on the same reporter aslanguage_server.ready.Despite millions of users on those builds emitting the sibling
language_server.readyevent,pyrefly.detectionshowed zero rows in telemetry. Root cause: the new event name was not declared in this GDPR allow-list, so it was scrubbed before ingestion.language_server.readyis declared here and flows fine;pyrefly.detectionwas missing.Change
Declares
pyrefly.detectionwith its properties:available,haspyreflytoml,haspyprojectsection,hasenvironmentbinary,promptdismissed,notificationenabled— the event-specific fields emitted by Pylance's_reportDetectionTelemetry.lsversion,failed— common properties, mirroring the siblinglanguage_server.readydeclaration.All properties are
SystemMetaData/ non-personal (booleans and the LS version).Impact
No runtime code change. Once a Python extension build containing this declaration reaches users, data will begin flowing from already-deployed Pylance clients that are already emitting the event.