GoogleCloudPlatform / google-cloud-visualstudio

Google Cloud Tools for Visual Studio
https://cloud.google.com/tools/visual-studio/docs/
Apache License 2.0
88 stars 51 forks source link

GoogleCloudToolbar extension on VS2017 stopped working #1064

Closed YingGCP closed 6 years ago

YingGCP commented 6 years ago

An user have installed the GoogleCloudToolbar extension on VS2017. It was working fine until one day it started throwing the below error. This error pops up as soon as I open VS.

"The 'GoogleCloudExtensionPackage' package did not load correctly.

The problem may have been caused by a configuration change or by the installation of another extension. You can get more information by examining the file 'xxxxxx/ActivityLog.xml'

Restarting Visual Studio could help resolve the issue"

The user uninstalled all other extensions that he downloaded, reinstalled googlecloud ext, resinstalled VS, repaired. Nothing fixed the issue. 'Publish to google cloud' option is disabled. Clicking on any other options like 'Manage Accounts' under GoogleCloud toolbar opens the same error pop up.

The ActivityLog is attached: ActivityLog.txt

YingGCP commented 6 years ago

Here's some additional information if needed:

YingGCP commented 6 years ago

The VS detailed version information. VS_Help_About_Info.txt

ILMTitan commented 6 years ago

Thank you so much for including the ActivityLog.xml. It looks like, somehow, one of your user accounts has multiple account user account files.

Go to %LOCALAPPDATA%\googlecloudvsextension\accounts and you will find several *.json files. Deleting them all (or just the ones with duplicate accounts) should fix this issue.

At least two of those *.json files have the same "account":"<user-email>" field, and the extension is crashing because of that.

ILMTitan commented 6 years ago

I am opening #1065 to track a fix for the underlying bug.

reshmakishore commented 6 years ago

Thanks. The above fix worked. There were 2 *.json files in the folder and it started working when I deleted both of them.

ILMTitan commented 6 years ago

Glad to hear you are about to use the extension again.