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

Failures while updating salesforce.salesforcedx-vscode-core extension #262

Closed
sandy081 opened this issue Jan 17, 2018 · 5 comments
Closed

Comments

@sandy081
Copy link

Hi,

I am a developer from VS Code team. I am analysing the trend of extension failures reported to our telemetry database when users install/update extensions in VS Code. We use error codes and send them to our telemetry database to understand when an extension is failing while it is being installed. Once understanding the reasons behind the failures, we are fixing in VS Code if there are any thereby making extension installation better.

As part of this, I have seen that the extension salesforce.salesforcedx-vscode-core has high failure rate (53%) recently in vscode insiders (last 7 days). Majority of the failures are coming from when we try to delete the extension folder with the same name+version as the extension being updated.

I would like to know if you are aware any failures or such related failures. It would be great if you can share that information so that we can improve it from our side.

@vazexqi
Copy link
Contributor

vazexqi commented Jan 17, 2018

@sandy081 - Thanks for reaching out to us. Could you point us to your automated tests (or describe the steps) that you were running so that we can reproduce this on our end and investigate more on the different failure conditions?

@sandy081
Copy link
Author

@vazexqi Unfortunately this data is not from automated tests, this data is from the real time usage of VS Code from users.

image

I categorise extension failures as follows:

  • GalleryFails: When requests to market place fails
  • IncompatibleFails: When user installs extension which is incompatible with his/her VS Code version
  • DownloadFails: When downloading the vsix fails
  • DeletingFails: Before extracting the vsix into a folder under extensions folder, I try to delete the folder if it exists.
  • ExtractingFails: When extracting the downloaded vsix into extensions folder
  • ValidateFails: When reading the manifest from the disk and validating it
  • LocalFails: When Reading the extracted extension or updating the metadata of extension back into disk.
  • UnknownFails: Other unknown reasons

From the above pic, salesforce.salesforcedx-vscode-core was updated around 77 times and update was failed only 41 times with a failure rate of 53% which does not look good. But, what worries me more is the number of times (75% of failures) it failed while deleting the folder in the disk.

To explain more about this failure, after downloading the new version vsix (say salesforce.salesforcedx-vscode-core-1.2.1) from the market place, I try to delete the folder salesforce.salesforcedx-vscode-core-1.2.1 from the extension folder if it exists. Delete failures are those if deleting this folder fails. Theoretically, this is not supposed to happen because the newly updated version folder should not exist in the disk, otherwise the update will be never triggered.

So, would like to know if you have seen any such failures or if users reported such. Also any information about why this could happen with this extension would be helpful.

Thanks

@guw
Copy link
Contributor

guw commented Jan 18, 2018

@sandy081 This is just guessing but what happens if a user install extensions that define a dependency on the salesforce.salesforcedx-vscode-core extension? Would that cause re-installations?

@sandy081
Copy link
Author

@guw No, we check if the extension is installed already. If there is a new version then new version is installed which gets extracted into a new folder.

@sandy081
Copy link
Author

Thanks a lot for helping here by providing insights

After investigating more, I figured out that root cause is extension auto updates that triggers updating the same extension from all open windows. This can lead to failures while deleting the directory. Will provide the fix in VS Code for this.

Closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants