mhutch / MonoDevelop.MSBuildEditor

Improved MSBuild editing support
Other
228 stars 26 forks source link

Cannot open .csproj file #13

Closed mrward closed 6 years ago

mrward commented 6 years ago

https://developercommunity.visualstudio.com/content/problem/293424/cannot-open-csproj-file.html

VS Mac 7.6.0.2005 or 2003. With MSBuild Editor 2.0.3 installed if you try to open a .csproj file in the editor using Tools - Edit File from the Solution pad you cannot open the file and see a status bar error of Value cannot be null. Parameter name: definition.

ERROR [2018-07-14 16:09:28Z]: 
System.ArgumentNullException: Value cannot be null.
Parameter name: definition
  at MonoDevelop.Ide.Editor.Highlighting.SyntaxHighlighting..ctor (MonoDevelop.Ide.Editor.Highlighting.SyntaxHighlightingDefinition definition, MonoDevelop.Ide.Editor.IReadonlyTextDocument document) [0x0004d] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Highlighting/SyntaxHighlighting.cs:38 
  at MonoDevelop.MSBuildEditor.MSBuildTextEditorExtension.CheckHighlighting () [0x00052] in <f70eaf2c3bba4e8c866c158ab2865fab>:0 
  at MonoDevelop.MSBuildEditor.MSBuildTextEditorExtension.Initialize () [0x0003b] in <f70eaf2c3bba4e8c866c158ab2865fab>:0 
  at MonoDevelop.Ide.Editor.Extension.TextEditorExtension.Initialize (MonoDevelop.Ide.Editor.TextEditor editor, MonoDevelop.Ide.Editor.DocumentContext context) [0x0003d] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor.Extension/TextEditorExtension.cs:65 
  at MonoDevelop.Ide.Editor.TextEditor.SetExtensionChain (MonoDevelop.Ide.Editor.DocumentContext documentContext, System.Collections.Generic.IEnumerable`1[T] extensions) [0x00053] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor/TextEditor.cs:1190 
  at MonoDevelop.Ide.Editor.TextEditor.InitializeExtensionChain (MonoDevelop.Ide.Editor.DocumentContext documentContext) [0x00102] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Editor/TextEditor.cs:1171 
  at MonoDevelop.Ide.Gui.Document.InitializeExtensionChain () [0x00000] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Document.cs:686 
  at MonoDevelop.Ide.Gui.Document.InitializeEditor () [0x00045] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Document.cs:717 
  at MonoDevelop.Ide.Gui.Document.OnDocumentAttached () [0x00008] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Document.cs:723 
  at MonoDevelop.Ide.Gui.Workbench.WrapDocument (MonoDevelop.Ide.Gui.IWorkbenchWindow window) [0x00056] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Workbench.cs:877 
  at MonoDevelop.Ide.Gui.ViewCommandHandlers..ctor (MonoDevelop.Ide.Gui.IWorkbenchWindow window) [0x0000d] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/ViewCommandHandlers.cs:50 
  at MonoDevelop.Ide.Gui.SdiWorkspaceWindow.CreateCommandHandler () [0x00000] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/SdiWorkspaceWindow.cs:122 
  at MonoDevelop.Ide.Gui.DefaultWorkbench.ShowView (MonoDevelop.Ide.Gui.ViewContent content, System.Boolean bringToFront, MonoDevelop.Ide.Gui.IViewDisplayBinding binding, MonoDevelop.Components.DockNotebook.DockNotebook notebook) [0x00120] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/DefaultWorkbench.cs:445 
  at MonoDevelop.Ide.Gui.LoadFileWrapper+<Invoke>d__8.MoveNext () [0x00274] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Workbench.cs:1616 
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x00037] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:187 
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:156 
  at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:128 
  at System.Runtime.CompilerServices.TaskAwaiter`1[TResult].GetResult () [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2018-02/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:357 
  at MonoDevelop.Ide.Gui.Workbench+<RealOpenFile>d__118.MoveNext () [0x00373] in /Users/vsts/agent/2.136.1/work/1/s/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/Workbench.cs:1096 
mhutch commented 6 years ago

Fixed by https://github.com/mhutch/MonoDevelop.MSBuildEditor/commit/d0d48a8e3548f31c1d82a09cbebf71caf67e8850, need to push an update

mhutch commented 6 years ago

Published the fix