roslyn: devenv crash on Windows 10 with VS 2015 when building from command-line

Version Used: Windows 10 Enterprise (Version 1511 Build 10586.0) Visual Studio Enterprise 2015 Version 14.0.25431.01 Update 3

Steps to Reproduce:

An example project which I used to reproduce the error can be found here: Example project

  1. Open “Developer Command Prompt for VS2015”
  2. Execute “devenv.com CodeAnalysisError.sln /rebuild”

Expected Behavior: Visual Studio builds the solution showing code analysis warnings on the command-line output.

Actual Behavior: Visual Studio crashes if code analysis is activated. In the Windows Event Log I find the following error (sorry, it’s a german windows so the log is in german but I think you can get the relevant parts):

Name der fehlerhaften Anwendung: devenv.exe, Version: 14.0.25420.1, Zeitstempel: 0x57685d85 Name des fehlerhaften Moduls: unknown, Version: 0.0.0.0, Zeitstempel: 0x00000000 Ausnahmecode: 0x80131623 Fehleroffset: 0x0f1b967e ID des fehlerhaften Prozesses: 0x1678 Startzeit der fehlerhaften Anwendung: 0x01d23b217e265a6c Pfad der fehlerhaften Anwendung: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe Pfad des fehlerhaften Moduls: unknown Berichtskennung: 15308bb3-3568-4fed-997d-ef36c47ebad4 Vollständiger Name des fehlerhaften Pakets: Anwendungs-ID, die relativ zum fehlerhaften Paket ist:

and the second error entry

Anwendung: devenv.exe Frameworkversion: v4.0.30319 Beschreibung: Die Anwendung forderte die Beendigung des Prozesses durch System.Environment.FailFast(Zeichenfolgenmeldung) an. Meldung: System.ArgumentException: Value does not fall within the expected range. at Microsoft.VisualStudio.Shell.Interop.IVsRunningDocumentTable4.GetDocumentMoniker(UInt32 cookie) at Microsoft.VisualStudio.LanguageServices.Implementation.ProjectSystem.MiscellaneousFilesWorkspace.Registration_WorkspaceChanged(Object sender, EventArgs e) at Microsoft.CodeAnalysis.WorkspaceRegistration.RaiseEvents() at Microsoft.CodeAnalysis.Workspace.<>c__DisplayClass199_0.<RegisterText>b__0() at Roslyn.Utilities.TaskExtensions.<>c__DisplayClass14_0.<ContinueWithAfterDelay>b__1(Task _) at Roslyn.Utilities.TaskExtensions.<>c__DisplayClass2_0.<SafeContinueWith>b__0(Task antecedent) at Roslyn.Utilities.TaskExtensions.<>c__DisplayClass6_01.<SafeContinueWith>b__0(Task t) Stapel: bei System.Environment.FailFast(System.String, System.Exception) bei Microsoft.CodeAnalysis.FailFast.OnFatalException(System.Exception) bei Microsoft.CodeAnalysis.ErrorReporting.FatalError.Report(System.Exception, System.Action1<System.Exception>) bei Microsoft.CodeAnalysis.ErrorReporting.FatalError.ReportUnlessCanceled(System.Exception) bei Roslyn.Utilities.TaskExtensions+<>c__DisplayClass6_01[[System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<SafeContinueWith>b__0(System.Threading.Tasks.Task) bei Microsoft.VisualStudio.Shell.Interop.IVsRunningDocumentTable4.GetDocumentMoniker(UInt32) bei Microsoft.VisualStudio.LanguageServices.Implementation.ProjectSystem.MiscellaneousFilesWorkspace.Registration_WorkspaceChanged(System.Object, System.EventArgs) bei Microsoft.CodeAnalysis.WorkspaceRegistration.RaiseEvents() bei Microsoft.CodeAnalysis.Workspace+<>c__DisplayClass199_0.<RegisterText>b__0() bei Roslyn.Utilities.TaskExtensions+<>c__DisplayClass14_0.<ContinueWithAfterDelay>b__1(System.Threading.Tasks.Task) bei Roslyn.Utilities.TaskExtensions+<>c__DisplayClass2_0.<SafeContinueWith>b__0(System.Threading.Tasks.Task) bei Roslyn.Utilities.TaskExtensions+<>c__DisplayClass6_01[[System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<SafeContinueWith>b__0(System.Threading.Tasks.Task) bei System.Threading.Tasks.ContinuationResultTaskFromTask`1[[System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].InnerInvoke() bei System.Threading.Tasks.Task.Execute() bei System.Threading.Tasks.Task.ExecutionContextCallback(System.Object) bei System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean) bei System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean) bei System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef) bei System.Threading.Tasks.Task.ExecuteEntry(Boolean) bei System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem() bei System.Threading.ThreadPoolWorkQueue.Dispatch() bei System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 24 (13 by maintainers)

Most upvoted comments

@nil4

is it safe to install this VSIX on VS 2015?

There is new metadata in there so this VSIX is compatible with 2017 but it should still install on 2015

how can I remove the VSIX, if it does not resolve the issue, or I run into other problems after installing it?

  1. Go to Extensions and Updates under tools image
  2. Go to Installed Extensions image
  3. Uninstall Roslyn Language Services image

@jmarolf Is there a way to uninstall the VSIX if Visual Studio doesn’t open due to the VSIX? One of these previous VSIX patches hosed my VS2015 install. Does /safemode do the trick? Found potential solution here: https://stackoverflow.com/a/32672070/1519839