Skip to content

Rename PEP723 telemetry events to inlineScript#1578

Merged
StellaHuang95 merged 1 commit into
microsoft:mainfrom
StellaHuang95:rename-inline-script-telemetry
Jun 11, 2026
Merged

Rename PEP723 telemetry events to inlineScript#1578
StellaHuang95 merged 1 commit into
microsoft:mainfrom
StellaHuang95:rename-inline-script-telemetry

Conversation

@StellaHuang95

Copy link
Copy Markdown
Contributor

What

Rename the two PEP 723 telemetry events to use an inlineScript prefix instead of PEP723:

Old New
PEP723.DETECTED inlineScript.detected
PEP723.EDITED inlineScript.edited
EventNames.PEP723_DETECTED EventNames.INLINE_SCRIPT_DETECTED
EventNames.PEP723_EDITED EventNames.INLINE_SCRIPT_EDITED

The new names are consistent with the rest of the module — inlineScriptMetadata.ts, InlineScriptLazyDetector, readInlineScriptMetadataFromFile, InlineScriptMetadata — and drop the PEP number from anything that leaves the machine.

The GDPR annotation keys were also realigned to match the wire names exactly ("inlineScript.detected" / "inlineScript.edited").

Why

I talked to the data platform team about why PEP723.DETECTED / PEP723.EDITED were missing from Kusto. They asked me to manually trigger the events and gave them my VS Code session ID. After I did, they could see every other event from that session — but not the two PEP 723 ones. They didn't know what was filtering them out either.

I don't know what's wrong yet. One guess is that the digits in the event name / GDPR key are tripping something in the ingestion or sanitization pipeline. This PR drops the numbers and renames the events to a clean alphabetic prefix to try again; if events start showing up in Kusto after this lands, that's our culprit.

Scope

Telemetry-only rename — no behavior change. Code that refers to the PEP 723 spec (parser, docstrings, design docs, API jsdoc) is intentionally untouched.

Files changed

  • src/common/telemetry/constants.ts — enum members, jsdoc, and __GDPR__ annotations
  • src/features/inlineScriptLazyDetector.tssendTelemetryEvent calls + class jsdoc + field comments + handler jsdoc
  • src/extension.ts — comment quoting the event names
  • src/test/features/inlineScriptLazyDetector.unit.test.ts — section comments + 10 test titles + 16 EventNames.* references

Verified

  • npm run lint clean
  • npm run unittest — all 1141 tests pass; the 10 renamed inlineScript.* tests show the new names

Trying an alphabetic prefix to debug why these events aren't reaching
Kusto. The data platform team confirmed every other event from a test
session arrived but the two PEP 723 ones were dropped without an
explanation; one guess is the digits in the name/GDPR key are tripping
something in ingestion. No behavior change otherwise — events are now
inlineScript.detected / inlineScript.edited and the GDPR keys match
the wire names exactly. Also aligned the enum names, jsdoc, test
titles, and the comment in extension.ts.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@StellaHuang95 StellaHuang95 force-pushed the rename-inline-script-telemetry branch from 8704aa9 to 3256564 Compare June 11, 2026 22:57

@edvilme edvilme 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.

LGTM, hopefully this helps :)

@StellaHuang95 StellaHuang95 merged commit 9c56441 into microsoft:main Jun 11, 2026
44 checks passed
@StellaHuang95 StellaHuang95 deleted the rename-inline-script-telemetry branch June 11, 2026 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants