Skip to content
This repository has been archived by the owner on Jun 21, 2023. It is now read-only.

Reverting extension in VS2017 causes errors with Extensions & Updates manager #1206

Closed
meaghanlewis opened this issue Aug 29, 2017 · 11 comments
Labels

Comments

@meaghanlewis
Copy link
Contributor

Version

  • GitHub Extension for Visual Studio version: ?
  • Visual Studio version: VS2017

What happened

Steps to reproduce:

  • In VS2017, go to Tools < Extensions and Updates and select GitHub extension.
  • Select to Revert.
  • Go through steps and finish revert
  • Close VS
  • Open VS after revert is complete
  • Go to Tools < Extensions and Updates
  • Error! And Extensions and Updates can't open

screen shot 2017-08-29 at 2 25 50 pm

After that I tried to install the latest vsix, and then saw this error:
screen shot 2017-08-29 at 2 28 50 pm
(I can provide the install log if that helps.)

The good thing is that the extension seems usable, but I can no longer manage it- or any other extensions, because I can't view them. I've also tried this with multiple versions of the extension, but this continues to happen.

@shana
Copy link
Contributor

shana commented Aug 30, 2017

@meaghanlewis Could you post the install log here?

@Michael-Eng Looks like we have another VS installer issue, could you help with this?

/cc @AArnott

@shana
Copy link
Contributor

shana commented Aug 30, 2017

So looks like this is a VS installer bug. MS is working on it.

@meaghanlewis
Copy link
Contributor Author

Here's the install log from this issue:
install log post revert of GHfVS.txt

@Michael-Eng
Copy link

Michael-Eng commented Aug 30, 2017

We're putting together the workaround instructions. Can you try these to see if they resolve the issue for you?

  1. Shutdown all instances of VS
  2. Update your state.json file
    • Backup your c:\programdata\Microsoft\VisualStudio\Packages_Instances[hashid]\state.json file
    • In an elevated command prompt, edit the state.json file and delete all GitHub entries in the file
  3. Delete the extension directory/directories that contain the GitHub extension. Since the GitHub extension installs to a random location, we need to find the folders
    • In an elevated command prompt, go to c:\program files (x86)\Microsoft\VisualStudio[Community/Pro/Enterprise]\Common7\IDE\Extensions
    • Run “dir /s GitHub” (note that there are asterisks before and after GitHub but they're not being displayed in this thread)
    • Delete the directories that contain the GitHub files
  4. Delete the extension cache files at c:\users[username]\AppData\Local\Microsoft\VisualStudio\15.0[hashid]\Extensions*.cache
  5. Restart VS and reinstall the GitHub extension

Thanks!

@meaghanlewis
Copy link
Contributor Author

Hi @Michael-Eng, thanks for these steps!

They work, but I actually only need to do steps 1 and 2 to be able to manage my extensions again.

@Michael-Eng
Copy link

Michael-Eng commented Aug 30, 2017

Thanks @meaghanlewis. Step 3 is required so that there aren't two copies of the GitHub extension installed (bad things will happen if we see more than one copy of the GitHub extension and try to load both) and 4 forces us to rescan all extensions. Thanks for verifying the steps.

The issue is fixed in 15.4. We have also posted these workaround steps here: https://developercommunity.visualstudio.com/content/problem/102178/error-installing-github-extension.html

@meaghanlewis
Copy link
Contributor Author

Okay, got it @Michael-Eng. I'll keep these workaround steps handy until this issue is fixed 😄

@shana
Copy link
Contributor

shana commented Aug 31, 2017

Thanks for all the help @Michael-Eng! I've updated the README and the website help section with a notice and links to the workarounds regarding this issue, hopefully we won't get a lot of users running into this before the fix is out 🤞

@shana
Copy link
Contributor

shana commented Sep 1, 2017

Update on how to bypass the Revert problem

A straightforward way of bypassing the "Revert" problem is to manually uninstall the extension on the command line:

  1. Shutdown VS 2017
  2. Open a Developer Command Prompt for VS 2017 in administrator mode by right-clicking on the Start menu shortcut and selecting Run as administrator
  3. run vsixinstaller /uninstall:c3d3dc68-c977-411f-b3e8-03b0dccf7dfc to uninstall the currently installed extension

After this is done, you can install the current version from the marketplace, or any previous version from our gallery feed:

  1. Go to Tools / Options / Extensions and Updates
  2. Add a new gallery with the name GitHub and url https://visualstudio.github.com/releases/feed.rss
  3. The gallery will now be available from Extensions and Updates inside the Online or Updates tab and you can pick from the last 10 or so versions.

@toddhd
Copy link

toddhd commented Sep 29, 2017

vsixinstaller /uninstall:c3d3dc68-c977-411f-b3e8-03b0dccf7dfc says uninstall failed. I had already previously tried upgrading/reverting several times. What else can I try? Can I manually uninstall this?

@drguthals
Copy link
Contributor

@grokys - do you know if @toddhd can manually uninstall if the uninstall command isn't working?

@toddhd - were you ever able to resolve this?

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

No branches or pull requests

5 participants