This repository was archived by the owner on Oct 2, 2021. It is now read-only.
Add versions to telemetry#307
Merged
roblourens merged 3 commits intomicrosoft:masterfrom Mar 16, 2018
Merged
Conversation
roblourens
reviewed
Mar 16, 2018
src/telemetry.ts
Outdated
| } | ||
|
|
||
| public addCustomGlobalProperty(additionalGlobalPropertiesPromise: Promise<any> | any): void { | ||
| this._actionsQueue = this._actionsQueue.then(async () => { |
Member
There was a problem hiding this comment.
Here's a suggestion for a different implementation. It might get the intent across a little better since yours is acting like a queue here but doesn't really need to be. But it's not a big difference so I leave it up to you which one to use.
const reportedPropertyP = additionalGlobalPropertiesPromise.then(prop => this._telemetryReporter.addCustomGlobalProperty, err => this.reportErrorWhileWaitingForProperty(err);
this._actionsQueue = Promise.join(
this._actionsQueue,
reportedPropertyP)
Contributor
Author
There was a problem hiding this comment.
I'm using this suggestion with Promise.all
src/chrome/chromeDebugSession.ts
Outdated
| logger.log('vscode-chrome-debug-core: ' + require('../../../package.json').version); | ||
| const coreVersion = require('../../../package.json').version; | ||
| logger.log('vscode-chrome-debug-core: ' + coreVersion); | ||
| telemetry.addCustomGlobalProperty( { "Versions.DebugAdapterCore": coreVersion }); |
Member
There was a problem hiding this comment.
Please use single quotes (trying to enforce this now, I need to set up the tslint rule)
added 2 commits
March 16, 2018 14:53
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Add versions to telemetry
We'll use this to add the debug adapter versions, and the browser user agent to telemetry
The code to add the browser user agent is on chrome-debug added on this PR: microsoft/vscode-chrome-debug#621