Skip to content

Conversation

@jpogran
Copy link
Contributor

@jpogran jpogran commented Apr 22, 2020

This commit adds a warning if the jpogran.puppet-vscode extension is
installed while the puppet.puppet-vscode extension is. This can cause
a race condition where each extension tries to register at the same
time, which will produce error message popups.

@jpogran jpogran added this to the 0.25.1 milestone Apr 22, 2020
@jpogran jpogran force-pushed the maint-alert-if-jpogran-extension-installed branch from 21fdafc to 3e3cd35 Compare April 22, 2020 01:15
src/extension.ts Outdated
export function activate(context: vscode.ExtensionContext) {
let pkg = vscode.extensions.getExtension('jpogran.puppet-vscode');
if (pkg){
let message = 'The "jpogran.puppet-vscode" extension has been detected. Please uninstall it by executing the following from the commandline: "code --uninstall-extension jpogran.puppet-vscode"';
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it worth mentioning why this is bad?

Copy link

Choose a reason for hiding this comment

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

Suggested change
let message = 'The "jpogran.puppet-vscode" extension has been detected. Please uninstall it by executing the following from the commandline: "code --uninstall-extension jpogran.puppet-vscode"';
let message = 'The "jpogran.puppet-vscode" extension has been detected. Is not maintained anymore. To uninstall it, execute the following from the commandline: "code --uninstall-extension jpogran.puppet-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.

I think Glenn meant the kind of detail I put in the commit message could be useful to tell the user. It's less important that its unmaintained compared to the race condition that will cause errors.

Copy link

Choose a reason for hiding this comment

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

the fact that I missed it in the commit message seems to indicate that glenn is right :-D

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated the text

This commit adds a warning if the `jpogran.puppet-vscode` extension is
installed while the `puppet.puppet-vscode` extension is. This can cause
a race condition where each extension tries to register at the same
time, which will produce error message popups.
@jpogran jpogran force-pushed the maint-alert-if-jpogran-extension-installed branch from 3e3cd35 to ef7a1e5 Compare April 22, 2020 19:48
@jpogran jpogran merged commit 7a13475 into puppetlabs:master Apr 23, 2020
@jpogran jpogran deleted the maint-alert-if-jpogran-extension-installed branch June 7, 2021 16:19
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.

3 participants