The crash happens on solution load - and it happens for a solution containing .net core 1.1 projects. The SonarLint analyzers have been working well for this solution for months now, so it was a surprise to see the crash this morning. Looks like Visual Studio automatically updated the SonarLint extension today to version 3.6.0.2584. If I revert to SonarLint version 3.5 I can load the solution again.
This is the visual studio crash stacktrace:
Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.ArgumentException
at System.ThrowHelper.ThrowArgumentException(System.ExceptionResource)
at System.Collections.Generic.Dictionary`2[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].Insert(System.__Canon, System.__Canon, Boolean)
at SonarLint.VisualStudio.Integration.Vsix.Suppression.LiveIssueFactory.BuildProjectPathToIdMap(Microsoft.VisualStudio.Shell.Interop.IVsSolution)
at SonarLint.VisualStudio.Integration.Vsix.Suppression.LiveIssueFactory..ctor(Microsoft.CodeAnalysis.Workspace, Microsoft.VisualStudio.Shell.Interop.IVsSolution)
at SonarLint.VisualStudio.Integration.Vsix.Suppression.SuppressionManager.SetupSuppressionHandling()
at SonarLint.VisualStudio.Integration.Vsix.Suppression.SuppressionManager.RefreshSuppresionHandling()
at SonarLint.VisualStudio.Integration.Vsix.Suppression.SuppressionManager.OnSolutionBindingChanged(System.Object, SonarLint.VisualStudio.Integration.ActiveSolutionBindingEventArgs)
at System.EventHandler`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].Invoke(System.Object, System.__Canon)
at SonarLint.VisualStudio.Integration.ActiveSolutionBoundTracker.RaiseAnalyzersChangedIfBindingChanged()
at SonarLint.VisualStudio.Integration.ActiveSolutionBoundTracker+<OnActiveSolutionChanged>d__17.MoveNext()
at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__6_0(System.Object)
at Microsoft.VisualStudio.Threading.JoinableTaskFactory+SingleExecuteProtector.TryExecute()
at Microsoft.VisualStudio.Threading.JoinableTaskFactory+SingleExecuteProtector+<>c.<.cctor>b__20_0(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at MS.Internal.CulturePreservingExecutionContext.Run(MS.Internal.CulturePreservingExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)