Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DO NOT MERGE] Initial check-in for supporting telemetry in vscode #6123

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

RodgeFu
Copy link
Contributor

@RodgeFu RodgeFu commented Feb 24, 2025

Support telemetry in vscode. fixes #5298

DO-NOT-MERGE until we finish the privacy review.

@azure-sdk
Copy link
Collaborator

azure-sdk commented Feb 24, 2025

All changed packages have been documented.

  • typespec-vscode
Show changes

typespec-vscode - feature ✏️

Support telemetry

@azure-sdk
Copy link
Collaborator

azure-sdk commented Feb 24, 2025

You can try these changes here

🛝 Playground 🌐 Website 🛝 VSCode Extension

@@ -10,6 +10,9 @@ jobs:
parameters:
useDotNet: true

- script: pnpm run update-telemetry-key $(vscode-telemetry-key)
workingDirectory: $(Build.SourcesDirectory)/packages/typespec-vscode

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@timotheeguerin , I need to update the telemetry-key to the PROD one when publishing vscode extension. Do you know how I can add the PROD key into the $(vscode-telemetry-key) varaible? And how can I test whether the updated pipeline works without actually doing a publish? thanks.

Copy link
Member

@timotheeguerin timotheeguerin Feb 24, 2025

Choose a reason for hiding this comment

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

does the key need to be private? our others don't as they can't be kept private anyway(and I assume this one neither)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no, it doesn't need to be private.

Copy link
Member

Choose a reason for hiding this comment

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

I’d say I would include them both right there then and just decide with a .env which one should be used.

Copy link
Contributor Author

@RodgeFu RodgeFu Feb 26, 2025

Choose a reason for hiding this comment

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

Talked with guys from AzureApiCenter vscode extension team. Although it's not sensitive and will be in the released package.json eventually, but they still store the key as secret var in pipeline instead of plain text in github (https://github.com/microsoft/vscode-azureapicenter/blob/dev/.github/workflows/cd.yml#L39-L44). I'm also more comfortable not to store PROD "key" as plain text in github and prefer to follow what they are doing.
I gave it a try and was able to add a secret to the "typespec -Publish" pipeline for the key successfully (https://dev.azure.com/azure-sdk/internal/_apps/hub/ms.vss-build-web.ci-designer-hub?pipelineId=3226&nonce=wqPmyYzOeUiSS5fefsbaeA%3D%3D&branch=main). Do you know how I can test the change without actually publish something? Do I have to comment the publish part, test and then uncomment...? thx

@RodgeFu RodgeFu changed the title [DO NOT MERGE] Initial change for support telemetry in vscode [DO NOT MERGE] Initial check-in for supporting telemetry in vscode Feb 24, 2025
@RodgeFu RodgeFu added the ide Issues for VS, VSCode, Monaco, etc. label Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ide Issues for VS, VSCode, Monaco, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support telemetry in vscode
3 participants