github / VisualStudio

GitHub Extension for Visual Studio
https://visualstudio.github.com
MIT License
2.37k stars 1.21k forks source link

Can't uninstall VSIX from VS 2017 RC #864

Open jcansdale opened 7 years ago

jcansdale commented 7 years ago

This seems to happen often, but not always.

  1. Install GitHub.VisualStudio.vsix.
  2. Uninstall using Tools / Extensions and Updates.
  3. Close Visual Studio and allow extension to uninstall (no warnings/errors).
  4. Open Visual Studio.
  5. Extension is still visible on Tools / Extensions and Updates.
  6. Try uninstalling again.
  7. Close Visual Studio and this time uninstall fails with: image
16/02/2017 09:39:56 - Microsoft VSIX Installer
16/02/2017 09:39:56 - -------------------------------------------
16/02/2017 09:39:56 - vsixinstaller.exe version:
16/02/2017 09:39:56 - 15.0.26206.0 built by: D15REL
16/02/2017 09:39:56 - -------------------------------------------
16/02/2017 09:39:56 - Command line parameters:
16/02/2017 09:39:56 - C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\vsixinstaller.exe,/appidinstallpath:C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.exe,/skuName:Enterprise,/skuVersion:15.0.26206.0,/appidname:Microsoft Visual Studio Enterprise 2017 RC,/u:c3d3dc68-c977-411f-b3e8-03b0dccf7dfc,/installas:2244,/callingprocessid:10984
16/02/2017 09:39:56 - -------------------------------------------
16/02/2017 09:39:56 - Microsoft VSIX Installer
16/02/2017 09:39:56 - -------------------------------------------
16/02/2017 09:39:56 - PKGDEF Information: Looking for master PkgDef file, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\master.pkgdef

16/02/2017 09:39:56 - PKGDEF Information: Creating PkgDefCacheNonVolatile
16/02/2017 09:39:56 - PKGDEF Information: Double-checking master pkgdef file
16/02/2017 09:39:56 - PKGDEF Information: PkgDefManagement initialized
16/02/2017 09:39:56 - PKGDEF Information: RootFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\

16/02/2017 09:39:56 - PKGDEF Information: ShellFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\

16/02/2017 09:39:56 - PKGDEF Information: PkgDefSearchPath, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\CommonExtensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.admin.pkgdef

16/02/2017 09:39:56 - PKGDEF Information: ImageManifestSearchPath, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\CommonExtensions;C:\Users\passp\AppData\Local\Microsoft\VisualStudio\15.0_eeba6487\Extensions

16/02/2017 09:39:56 - PKGDEF Information: ApplicationExtensionsFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions

16/02/2017 09:39:56 - PKGDEF Information: "ZeroImpact" = dword:0, "MergeRegistry" = dword:3
16/02/2017 09:39:56 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 09:39:56 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 09:39:56 - PKGDEF Information: User extensions enabled by setting, Path: HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\15.0_eeba6487\ExtensionManager\EnableAdminExtensions

16/02/2017 09:39:56 - PKGDEF Information: PkgDefCache flags, PKGDEF: 7001
16/02/2017 09:39:56 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 09:39:56 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 09:39:56 - PKGDEF Information: PkgDefManagement startup complete
16/02/2017 09:39:57 - Initializing Uninstall...
16/02/2017 09:39:57 - Extension Details...
16/02/2017 09:39:57 -   Identifier         : c3d3dc68-c977-411f-b3e8-03b0dccf7dfc
16/02/2017 09:39:57 -   Name               : GitHub Extension for Visual Studio
16/02/2017 09:39:57 -   Author             : GitHub, Inc
16/02/2017 09:39:57 -   Version            : 2.2.0.8
16/02/2017 09:39:57 -   Description        : A Visual Studio Extension that brings the GitHub Flow into Visual Studio.
16/02/2017 09:39:57 -   Locale             : en-US
16/02/2017 09:39:57 -   MoreInfoURL        : https://visualstudio.github.com/
16/02/2017 09:39:57 -   InstalledByMSI     : False
16/02/2017 09:39:57 -   SupportedFrameworkVersionRange : [4.5,)
16/02/2017 09:39:57 - 
16/02/2017 09:39:57 -   Supported Products : 
16/02/2017 09:39:57 -       Microsoft.VisualStudio.Community
16/02/2017 09:39:57 -           Version : [14.0,15.0]
16/02/2017 09:39:57 - 
16/02/2017 09:39:57 -   References         : 
16/02/2017 09:39:57 -       -------------------------------------------------------
16/02/2017 09:39:57 -       Identifier   : Microsoft.VisualStudio.MPF.14.0
16/02/2017 09:39:57 -       Name         : Visual Studio MPF 14.0
16/02/2017 09:39:57 -       Version      : [14.0,)
16/02/2017 09:39:57 -       MoreInfoURL  : 
16/02/2017 09:39:57 -       Nested       : No
16/02/2017 09:39:57 - 
16/02/2017 09:39:57 -   Prerequisites      : 
16/02/2017 09:39:57 -       -------------------------------------------------------
16/02/2017 09:39:57 -       Identifier   : Microsoft.VisualStudio.Component.CoreEditor
16/02/2017 09:39:57 -       Name         : Visual Studio core editor
16/02/2017 09:39:57 -       Version      : [15.0.25824.0,16.0)
16/02/2017 09:39:57 - 
16/02/2017 09:39:57 - 
16/02/2017 09:40:04 - The following target products have been selected...
16/02/2017 09:40:04 -   Microsoft Visual Studio Enterprise 2017 RC
16/02/2017 09:40:04 - 
16/02/2017 09:40:04 - Uninstalling 'GitHub Extension for Visual Studio', version 2.2.0.8.
16/02/2017 09:40:07 - System.InvalidOperationException: Uninstall of GitHub Extension for Visual Studio failed. To uninstall this extension please uninstall all of the following components: 
   at Microsoft.VisualStudio.ExtensionManager.ExtensionEngineImpl.PerformSetupEngineUnInstall(IInstalledExtension extension)
   at Microsoft.VisualStudio.ExtensionManager.ExtensionEngineImpl.UninstallInternal(IInstalledExtension extension, Boolean forceDelete, Version targetedVSVersion)
   at Microsoft.VisualStudio.ExtensionManager.ExtensionEngineImpl.Uninstall(IInstalledExtension extension, Version targetedVSVersion)
   at VSIXInstaller.InstallProgressPage.UninstallVsix(String vsixId, SupportedVSSKU targetSku, IProgress`1 progress)

This has made testing the extension in VS 2017 RC4, super painful. 😢

The way I've been unscrambling this is as follows:

  1. Open explorer on: \Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions
  2. Search for GitHub.
  3. Delete the folder that contains the GitHub extension/assemblies.
  4. Make the Extensions\extensions.configurationchanged file editable by the current user.
  5. Modify and save the extensions.configurationchanged file.
  6. Open VS 2017 and the extension is now gone.

A bit of a faff. 😉

jcansdale commented 7 years ago

I'm now unable to uninstall the extension. 😢

Here's the log:

16/02/2017 15:07:32 - Microsoft VSIX Installer
16/02/2017 15:07:32 - -------------------------------------------
16/02/2017 15:07:32 - vsixinstaller.exe version:
16/02/2017 15:07:32 - 15.0.26206.0 built by: D15REL
16/02/2017 15:07:32 - -------------------------------------------
16/02/2017 15:07:32 - Command line parameters:
16/02/2017 15:07:32 - C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\vsixinstaller.exe,/appidinstallpath:C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.exe,/skuName:Enterprise,/skuVersion:15.0.26206.0,/appidname:Microsoft Visual Studio Enterprise 2017 RC,/u:c3d3dc68-c977-411f-b3e8-03b0dccf7dfc,/installas:2412,/callingprocessid:12524
16/02/2017 15:07:32 - -------------------------------------------
16/02/2017 15:07:32 - Microsoft VSIX Installer
16/02/2017 15:07:32 - -------------------------------------------
16/02/2017 15:07:34 - PKGDEF Information: Looking for master PkgDef file, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\master.pkgdef

16/02/2017 15:07:34 - PKGDEF Information: Creating PkgDefCacheNonVolatile
16/02/2017 15:07:34 - PKGDEF Information: Double-checking master pkgdef file
16/02/2017 15:07:34 - PKGDEF Information: PkgDefManagement initialized
16/02/2017 15:07:34 - PKGDEF Information: RootFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\

16/02/2017 15:07:34 - PKGDEF Information: ShellFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\

16/02/2017 15:07:34 - PKGDEF Information: PkgDefSearchPath, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\CommonExtensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.admin.pkgdef

16/02/2017 15:07:34 - PKGDEF Information: ImageManifestSearchPath, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions;C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\CommonExtensions;C:\Users\passp\AppData\Local\Microsoft\VisualStudio\15.0_eeba6487\Extensions

16/02/2017 15:07:34 - PKGDEF Information: ApplicationExtensionsFolder, Path: C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions

16/02/2017 15:07:34 - PKGDEF Information: "ZeroImpact" = dword:0, "MergeRegistry" = dword:3
16/02/2017 15:07:34 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 15:07:34 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 15:07:34 - PKGDEF Information: User extensions enabled by setting, Path: HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\15.0_eeba6487\ExtensionManager\EnableAdminExtensions

16/02/2017 15:07:34 - PKGDEF Information: PkgDefCache flags, PKGDEF: 7001
16/02/2017 15:07:34 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 15:07:34 - PKGDEF Information: Could not find ConfigurationChanged timestamp., PKGDEF: 80070002
16/02/2017 15:07:34 - PKGDEF Information: PkgDefManagement startup complete
16/02/2017 15:07:37 - Initializing Uninstall...
16/02/2017 15:07:37 - Extension Details...
16/02/2017 15:07:37 -   Identifier         : c3d3dc68-c977-411f-b3e8-03b0dccf7dfc
16/02/2017 15:07:37 -   Name               : GitHub Extension for Visual Studio
16/02/2017 15:07:37 -   Author             : GitHub, Inc
16/02/2017 15:07:37 -   Version            : 2.2.0.10
16/02/2017 15:07:37 -   Description        : A Visual Studio Extension that brings the GitHub Flow into Visual Studio.
16/02/2017 15:07:37 -   Locale             : en-US
16/02/2017 15:07:37 -   MoreInfoURL        : https://visualstudio.github.com/
16/02/2017 15:07:37 -   InstalledByMSI     : False
16/02/2017 15:07:37 -   SupportedFrameworkVersionRange : [4.5,)
16/02/2017 15:07:37 - 
16/02/2017 15:07:37 -   Supported Products : 
16/02/2017 15:07:37 -       Microsoft.VisualStudio.Community
16/02/2017 15:07:37 -           Version : [14.0,15.0]
16/02/2017 15:07:37 - 
16/02/2017 15:07:37 -   References         : 
16/02/2017 15:07:37 -       -------------------------------------------------------
16/02/2017 15:07:37 -       Identifier   : Microsoft.VisualStudio.MPF.14.0
16/02/2017 15:07:37 -       Name         : Visual Studio MPF 14.0
16/02/2017 15:07:37 -       Version      : [14.0,)
16/02/2017 15:07:37 -       MoreInfoURL  : 
16/02/2017 15:07:37 -       Nested       : No
16/02/2017 15:07:37 - 
16/02/2017 15:07:37 -   Prerequisites      : 
16/02/2017 15:07:37 -       -------------------------------------------------------
16/02/2017 15:07:37 -       Identifier   : Microsoft.VisualStudio.Component.CoreEditor
16/02/2017 15:07:37 -       Name         : Visual Studio core editor
16/02/2017 15:07:37 -       Version      : [15.0.25824.0,16.0)
16/02/2017 15:07:37 - 
16/02/2017 15:07:37 - 
16/02/2017 15:07:48 - The following target products have been selected...
16/02/2017 15:07:48 -   Microsoft Visual Studio Enterprise 2017 RC
16/02/2017 15:07:48 - 
16/02/2017 15:07:50 - Uninstalling 'GitHub Extension for Visual Studio', version 2.2.0.10.
16/02/2017 15:07:57 - Package Microsoft.Windows.UniversalCRT.Msu.8 is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.2,6.3)'.
16/02/2017 15:07:57 - Package Microsoft.Windows.UniversalCRT.Msu.81 is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.3,6.4)'.
16/02/2017 15:07:57 - Package Microsoft.Net.4.6.FullRedist is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1.1,6.4)'.
16/02/2017 15:07:57 - Package Microsoft.Windows.UniversalCRT.Msu.7 is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.2)'.
16/02/2017 15:07:57 - Package Microsoft.DiagnosticsHub.KB2882822.Win7 is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.2)'.
16/02/2017 15:07:57 - Package WebSocket4NetV2 is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.2)'.
16/02/2017 15:07:57 - Package Microsoft.Net.4.6.1.FullRedist is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1.1,10.0.10241)'.
16/02/2017 15:07:57 - Package Microsoft.Windows.81SDK.Store.DirectX.Msi is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.3]'.
16/02/2017 15:07:57 - Package Microsoft.Windows.81SDK.Store.DirectX.Msi is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.3]'.
16/02/2017 15:07:57 - Package Microsoft.Windows.81SDK.Desktop.DirectX.Msi is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.3]'.
16/02/2017 15:07:57 - Package Microsoft.Windows.81SDK.Desktop.DirectX.Msi is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '[6.1,6.3]'.
16/02/2017 15:07:58 - Package Microsoft.VisualStudio.OfficeDeveloperTools.WindowsIdentityFoundation.Msu is not applicable. Skipping it due to the following reason(s): The current OS Version '10.0.14393.0' is not in the supported version range '(,6.2)'.
16/02/2017 15:08:16 - Successfully uninstalled GitHub Extension for Visual Studio.
jcansdale commented 7 years ago

It looks like this issue is very much related to the extension being installed for all users:

  <Installation AllUsers="true">
    <InstallationTarget Id="Microsoft.VisualStudio.Community" Version="[14.0,15.0]" />
  </Installation>

If I change to AllUsers="false", the VSIX will happily install itself, even when it's broken for all users. It seems if we want to test a standalone VSIX (not installed vis Extensions and Updates), we will need to set AllUsers="false".