问题
My Visual Studio 2013 is crashing when I trying to check in my pending changes everytime. How can I solve it?
Crash Log :
System.UnauthorizedAccessException: Package 'SccProviderPackage' failed to load.
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode)
at Microsoft.VisualStudio.ErrorHandler.ThrowOnFailure(Int32 hr, Int32[] expectedHRFailure)
at Microsoft.TeamFoundation.Git.Provider.ServiceProviderExtensionMethods.EnsurePackageLoaded(IServiceProvider serviceProvider, Guid packageGuid)
at Microsoft.TeamFoundation.Git.Provider.ServiceProviderExtensionMethods.EnsureSccAndTfPackagesLoaded(IServiceProvider serviceProvider)
at Microsoft.TeamFoundation.Git.Provider.Repositories.GitTeamProjectExtendedInfoProvider.set_ServiceProvider(IServiceProvider value)
at Microsoft.VisualStudio.TeamFoundation.TeamExplorer.ConnectPage.ConnectPageVS.Initialize(Object sender, PageInitializeEventArgs e)
at Microsoft.TeamFoundation.Controls.WPF.TeamExplorer.Framework.TeamExplorerPageHost.Initialize(TeamExplorerPageContext context)
回答1:
I have fixed it with these steps;
Clean the Cache folder on client computer. The folder path is: C:\Users\username\AppData\Local\Microsoft\Team Foundation\5.0\Cache.
Clean the Cache folder on Server machine. The folder path is: C:\ProgramData\Microsoft\Team Foundation\Web Access\Cache_v11.0
After cleaned, on Server machine, click Start and select Run… to open the dialog box, then input iisreset.exe
and click OK, wait it run completely.
回答2:
It looks like you are have a corrupted install of Visual Studio. You can try to 'repair' it from "Add/Remove Programs". If that does not work you are likely going to have to Uninstall and re-install.
You should get the latest binaries from http://www.microsoft.com/en-us/download/details.aspx?id=42666 o9r MSDN.
回答3:
I needed to delete my temp directory
C:\Users\username\AppData\Local\Temp
来源:https://stackoverflow.com/questions/23587666/visual-studio-crashing-when-checking-in