Bug 5039 - [regression] [3.0] mdtool cannot build from command-line
Summary: [regression] [3.0] mdtool cannot build from command-line
Status: RESOLVED FIXED
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Project Model ()
Version: Trunk
Hardware: PC Mac OS
: Highest normal
Target Milestone: ---
Assignee: Lluis Sanchez
URL:
: 4973 ()
Depends on:
Blocks:
 
Reported: 2012-05-11 22:17 UTC by Sebastien Pouliot
Modified: 2012-05-22 19:02 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
MonoDevelop3.0.1CrashReport.txt (67.75 KB, text/plain)
2012-05-22 16:33 UTC, shill
Details
Crash logs ZIP (220.34 KB, application/x-zip-compressed)
2012-05-22 17:25 UTC, shill
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Sebastien Pouliot 2012-05-11 22:17:45 UTC
Trying to build MT unit tests applications now fails with:

make[1]: *** [run-dev-dontlink] Error 2
/Applications/MonoDevelop.app/Contents/MacOS/mdtool -v build -t:Build "-c:Debug|iPhoneSimulator" dontlink/dontlink.csproj
MonoDevelop Build Tool
out of sync
FATAL ERROR [2012-05-11 21:22:19Z]: System.InvalidOperationException: out of sync
  at System.Collections.Generic.Dictionary`2+Enumerator[System.String,MonoDevelop.Core.Assemblies.SystemAssembly].VerifyState () [0x00033] in /private/tmp/monobuild/build/BUILD/mono-2.10.9/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:958 
  at System.Collections.Generic.Dictionary`2+Enumerator[System.String,MonoDevelop.Core.Assemblies.SystemAssembly].MoveNext () [0x00000] in /private/tmp/monobuild/build/BUILD/mono-2.10.9/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:880 
  at MonoDevelop.Core.Assemblies.AssemblyContext+<FindNewerAssembliesSameName>c__Iterator6.MoveNext () [0x00134] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Assemblies/AssemblyContext.cs:321 
  at MonoDevelop.Core.Assemblies.AssemblyContext.FindInstalledAssembly (System.String fullname, System.String package, MonoDevelop.Core.Assemblies.TargetFramework fx) [0x00162] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Assemblies/AssemblyContext.cs:304 
  at MonoDevelop.Core.Assemblies.ComposedAssemblyContext.FindInstalledAssembly (System.String fullname, System.String package, MonoDevelop.Core.Assemblies.TargetFramework fx) [0x00019] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Assemblies/ComposedAssemblyContext.cs:169 
  at MonoDevelop.Core.Assemblies.ComposedAssemblyContext.FindInstalledAssembly (System.String fullname, System.String package, MonoDevelop.Core.Assemblies.TargetFramework fx) [0x00019] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Assemblies/ComposedAssemblyContext.cs:169 
  at MonoDevelop.Projects.ProjectReference.UpdatePackageReference () [0x0001e] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectReference.cs:346 
  at MonoDevelop.Projects.ProjectReference.SetOwnerProject (MonoDevelop.Projects.DotNetProject project) [0x00007] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectReference.cs:100 
  at MonoDevelop.Projects.DotNetProject.OnItemsAdded (IEnumerable`1 objs) [0x0001f] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/DotNetProject.cs:1085 
  at MonoDevelop.IPhone.IPhoneProject.OnItemsAdded (IEnumerable`1 objs) [0x00063] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/md-addins/MonoDevelop.IPhone/MonoDevelop.IPhone/Project/IPhoneProject.cs:202 
  at MonoDevelop.Projects.ProjectItemCollection`1[MonoDevelop.Projects.ProjectItem].NotifyAdded (IEnumerable`1 items, Boolean comesFromParent) [0x0009a] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectItemCollection.cs:153 
  at MonoDevelop.Projects.ProjectItemCollection`1[MonoDevelop.Projects.ProjectItem].OnItemAdded (MonoDevelop.Projects.ProjectItem item) [0x00017] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectItemCollection.cs:113 
  at MonoDevelop.Projects.ItemCollection`1[MonoDevelop.Projects.ProjectItem].InsertItem (Int32 index, MonoDevelop.Projects.ProjectItem item) [0x00008] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ItemCollection.cs:39 
  at System.Collections.ObjectModel.Collection`1[MonoDevelop.Projects.ProjectItem].Add (MonoDevelop.Projects.ProjectItem item) [0x0000c] in /private/tmp/monobuild/build/BUILD/mono-2.10.9/mcs/class/corlib/System.Collections.ObjectModel/Collection.cs:74 
  at MonoDevelop.Projects.Formats.MSBuild.MSBuildProjectHandler.Load (IProgressMonitor monitor, MonoDevelop.Projects.Formats.MSBuild.MSBuildProject msproject) [0x00098] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectHandler.cs:499 
  at MonoDevelop.Projects.Formats.MSBuild.MSBuildProjectHandler.Load (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat expectedFormat, System.String language, System.Type itemClass) [0x001d0] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectHandler.cs:304 
  at MonoDevelop.Projects.Extensions.DotNetProjectNode.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat expectedFormat, System.String itemGuid) [0x00016] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Extensions/DotNetProjectNode.cs:66 
  at MonoDevelop.Projects.Formats.MSBuild.MSBuildProjectService.LoadItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat expectedFormat, System.String typeGuid, System.String itemGuid) [0x00024] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectService.cs:91 
  at MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat.ReadFile (FilePath file, System.Type expectedType, IProgressMonitor monitor) [0x0002b] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildFileFormat.cs:163 
  at MonoDevelop.Projects.ProjectService.ReadFile (IProgressMonitor monitor, System.String file, System.Type expectedType, MonoDevelop.Projects.FileFormat& format) [0x0002d] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs:310 
  at MonoDevelop.Projects.ProjectService+<ReadSolutionItem>c__AnonStorey6B.<>m__4C (IProgressMonitor , System.String ) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs:208 
  at MonoDevelop.Projects.DefaultProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs:672 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Autotools.MakefileProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/addins/MonoDevelop.Autotools/MakefileProjectServiceExtension.cs:69 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.CompiledAssemblyExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x0003e] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CompiledAssemblyProject.cs:223 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:102 
  at MonoDevelop.Projects.ProjectServiceExtension.LoadSolutionItem (IProgressMonitor monitor, System.String fileName, MonoDevelop.Projects.Extensions.ItemLoadCallback callback) [0x0000c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:93 
  at MonoDevelop.Projects.ProjectService.ReadSolutionItem (IProgressMonitor monitor, System.String file) [0x00059] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectService.cs:206 
  at MonoDevelop.Projects.BuildTool.Run (System.String[] arguments) [0x001e9] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/BuildTool.cs:111 
  at MonoDevelop.Core.ApplicationService.StartApplication (System.String appId, System.String[] parameters) [0x0004c] in /Users/builder/data/lanes/monodevelop-mac-3.0.0/bd819ea0/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Core/ApplicationService.cs:50 

(mdtool:77941): Gtk-CRITICAL **: gtk_main_quit: assertion `main_loops != NULL' failed
make[2]: *** [build-sim-dontlink] Error 255
Comment 1 Sebastien Pouliot 2012-05-12 10:04:09 UTC
It fails on my iMac (Snow Leopard) using MonoTouch 5.2.x

MonoDevelop 3.0.0
Installation UUID: ad97da07-e884-4ee6-8dcb-27f0ada6432b
Runtime:
	Mono 2.10.9 (tarball Mon May  7 20:25:51 EDT 2012)
	GTK 2.24.10
	GTK# (2.12.0.0)
	Package version: 210090011
Apple Developer Tools:
	 Xcode 4.2 (828)
	 Build 4C199
Monotouch: 5.2.12
Mono for Android not installed
Build information:
	Release ID: 30000000
	Git revision: bd819ea0fae289936c04b3be09e46483cf4ebc53-dirty
	Build date: 2012-05-11 18:45:18+0000
	Xamarin addins: 621394496750d6f26838c7f1c6e6348b007407ae
Operating System:
	Mac OS X 10.6.8
	Darwin imac.local 10.8.0 Darwin Kernel Version 10.8.0
	    Tue Jun  7 16:32:41 PDT 2011
	    root:xnu-1504.15.3~1/RELEASE_X86_64 x86_64
Comment 2 Sebastien Pouliot 2012-05-12 10:05:14 UTC
But it works on my Mac Book Air running Lion and MT 5.3.x


MonoDevelop 3.0.0
Installation UUID: bee4867d-4623-46b2-a743-14abdcde7192
Runtime:
	Mono 2.10.9 (tarball Mon May  7 20:25:51 EDT 2012)
	GTK 2.24.10
	GTK# (2.12.0.0)
	Package version: 210090011
Apple Developer Tools:
	 Xcode 4.3.2 (1177)
	 Build 4E2002
Monotouch: 5.3.4
Mono for Android: 4.2.1.196198126
Android SDK: /opt/android/sdk
Supported Android versions:
	Version: 1.6	ApiLevel: 4
	Version: 2.1	ApiLevel: 7
	Version: 2.2	ApiLevel: 8
	Version: 2.3	ApiLevel: 10
	Version: 3.1	ApiLevel: 12
	Version: 4.0	ApiLevel: 14
	Version: 4.0.3	ApiLevel: 15
Java SDK: /usr/bin

Build information:
	Release ID: 30000000
	Git revision: bd819ea0fae289936c04b3be09e46483cf4ebc53-dirty
	Build date: 2012-05-11 18:45:18+0000
	Xamarin addins: 621394496750d6f26838c7f1c6e6348b007407ae
Operating System:
	Mac OS X 10.7.4
	Darwin mba.local 11.4.0 Darwin Kernel Version 11.4.0
	    Mon Apr  9 19:32:15 PDT 2012
	    root:xnu-1699.26.8~1/RELEASE_X86_64 x86_64
Comment 3 Sebastien Pouliot 2012-05-12 10:05:51 UTC
it worked identically on both boxes just before the update (I run those tests several times per day)
Comment 4 Sebastien Pouliot 2012-05-12 20:01:25 UTC
I also get a

(mdtool:10670): Gtk-CRITICAL **: gtk_main_quit: assertion `main_loops != NULL' failed

from my Lion / MBA. E.g.

Embedding provisioning profile
Processing entitlements file
Preparing resources rules
Signing application
   codesign -v -f -s "66374BE26F13432705963D0908BAD20A289B1EA8" "--resource-rules=/Developer/MonoTouch/Source/monotouch/tests/monotouch-test/bin/iPhone/Debug/monotouchtest.app/ResourceRules.plist" --entitlements
   "/Developer/MonoTouch/Source/monotouch/tests/monotouch-test/bin/iPhone/Debug/monotouchtest.xcent" "/Developer/MonoTouch/Source/monotouch/tests/monotouch-test/bin/iPhone/Debug/monotouchtest.app"
   /Developer/MonoTouch/Source/monotouch/tests/monotouch-test/bin/iPhone/Debug/monotouchtest.app: signed bundle with Mach-O thin (armv6) [com.xamarin.monotouch-test]

(mdtool:10670): Gtk-CRITICAL **: gtk_main_quit: assertion `main_loops != NULL' failed
Comment 5 Mikayla Hutchinson [MSFT] 2012-05-14 10:59:09 UTC
*** Bug 4973 has been marked as a duplicate of this bug. ***
Comment 6 shill 2012-05-15 17:54:05 UTC
I am experiencing the same error using mdtool.

A quick solution is critical since this completly haults our build automation.


     [exec]       Loading projects ..
     [exec] ERROR [2012-05-15 14:02:28Z]: Error while trying to load the project /Users/.../project.csproj
     [exec] System.InvalidOperationException: out of sync
     [exec]   at System.Collections.Generic.Dictionary`2+Enumerator[System.String,MonoDevelop.Core.Assemblies.SystemAssembly].VerifyState () [0x00033] in /private/tmp/monobuild/build/BUILD/mono-2.10.9/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:958 
     [exec]   at System.Collections.Generic.Dictionary`2+Enumerator[System.String,MonoDevelop.Core.Assemblies.SystemAssembly].MoveNext () [0x00000] in /private/tmp/monobuild/build/BUILD/mono-2.10.9/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:880 



MonoDevelop 3.0 (3.0.1)
Installation UUID: 2f391317-622e-4e19-bdb6-ad8a92a2509d
Runtime:
	Mono 2.10.9 (tarball Mon May  7 20:25:51 EDT 2012)
	GTK 2.24.10
	GTK# (2.12.0.0)
	Package version: 210090011
Mono for Android not installed
Apple Developer Tools:
	 Xcode 4.2 (828)
	 Build 4C199
Monotouch: 5.2.11
Build information:
	Release ID: 30001000
	Git revision: 6642975fcf75fabbaf71a2ce79cdd65cd7db812a-dirty
	Build date: 2012-05-14 11:09:56+0000
	Xamarin addins: a1563f182f5d7a68e0ba06beda0a39f9fe073016
Operating System:
	Mac OS X 10.6.8
	Darwin shill-iMac.local 10.8.0 Darwin Kernel Version 10.8.0
	    Tue Jun  7 16:33:36 PDT 2011
	    root:xnu-1504.15.3~1/RELEASE_I386 i386
Comment 7 Mikayla Hutchinson [MSFT] 2012-05-15 22:28:15 UTC
I can't see any obvious commits that could cause this. It might be an older race that's been exposed by perf changes.
Comment 8 shill 2012-05-15 23:51:05 UTC
If I restore the MonoDevelop.app to version 2.8.8.4 I am able to build with no errors.
Comment 9 Mikayla Hutchinson [MSFT] 2012-05-17 20:34:13 UTC
I think I found the problem, by logging the threads that access the assembly context's dictionary. Some other thread from the addin engine is registering packages AFTER the project system force-initialized the system assembly service:
Thread 1
   at System.Environment.get_StackTrace()
   at MonoDevelop.Core.Assemblies.AssemblyContext.CheckLastThread()
   at MonoDevelop.Core.Assemblies.AssemblyContext.AddAssembly(System.String assemblyfile, MonoDevelop.Core.Assemblies.AssemblyInfo ainfo, MonoDevelop.Core.Assemblies.SystemPackage package)
   at MonoDevelop.Core.Assemblies.TargetRuntime.RegisterSystemAssemblies(MonoDevelop.Core.Assemblies.TargetFramework fx)
   at MonoDevelop.Core.Assemblies.TargetRuntime.CreateFrameworks()
   at MonoDevelop.Core.Assemblies.TargetRuntime.RunInitialization()
   at MonoDevelop.Core.Assemblies.TargetRuntime.BackgroundInitialize()
   at MonoDevelop.Core.Assemblies.TargetRuntime.EnsureInitialized()
   at MonoDevelop.Core.Assemblies.SystemAssemblyService.EnsureRuntimesInitialized()
   at MonoDevelop.Core.Assemblies.SystemAssemblyService.GetTargetFramework(MonoDevelop.Core.Assemblies.TargetFrameworkMoniker id)
   at MonoDevelop.Projects.DotNetProject.get_TargetFramework()
   at MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat.CanWriteFile(System.Object obj)
   at MonoDevelop.Projects.FileFormat.CanWrite(System.Object obj)
   at MonoDevelop.Projects.ProjectService.GetDefaultFormat(System.Object ob)
   at MonoDevelop.Projects.SolutionEntityItem.InitializeItemHandler()
   at MonoDevelop.Projects.SolutionItem.get_ItemHandler()
   at MonoDevelop.Projects.DotNetProject.OnEndLoad()
   at MonoDevelop.Projects.SolutionItem.MonoDevelop.Projects.ILoadController.EndLoad()
   at MonoDevelop.Projects.Extensions.LoadOperation.End()
   at MonoDevelop.Projects.Extensions.ProjectExtensionUtil.EndLoadOperation()
   at MonoDevelop.Projects.Formats.MSBuild.SlnFileFormat.ReadFile(System.String fileName, MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat format, IProgressMonitor monitor)
   at MonoDevelop.Projects.Formats.MSBuild.MSBuildFileFormat.ReadFile(FilePath file, System.Type expectedType, IProgressMonitor monitor)
   at MonoDevelop.Projects.ProjectService.ReadFile(IProgressMonitor monitor, System.String file, System.Type expectedType, MonoDevelop.Projects.FileFormat ByRef format)
   at MonoDevelop.Projects.ProjectService.InternalReadWorkspaceItem(System.String file, IProgressMonitor monitor)
   at MonoDevelop.Projects.DefaultProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Autotools.MakefileProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectServiceExtension.LoadWorkspaceItem(IProgressMonitor monitor, System.String fileName)
   at MonoDevelop.Projects.ProjectService.ReadWorkspaceItem(IProgressMonitor monitor, System.String file)
   at MonoDevelop.Projects.BuildTool.Run(System.String[] arguments)
   at MonoDevelop.Core.ApplicationService.StartApplication(System.String appId, System.String[] parameters)
   at MonoDevelopProcessHost.Main(System.String[] args)
Thread 5
   at System.Environment.get_StackTrace()
   at MonoDevelop.Core.Assemblies.AssemblyContext.CheckLastThread()
   at MonoDevelop.Core.Assemblies.AssemblyContext+<GetAssembliesFromFullNameInternal>c__Iterator3.MoveNext()
   at System.Linq.Enumerable.Any(IEnumerable`1 source, System.Func`2 predicate)
   at MonoDevelop.Core.Assemblies.AssemblyContext.RegisterPackage(MonoDevelop.Core.Assemblies.SystemPackageInfo pinfo, Boolean isInternal, Mono.PkgConfig.PackageAssemblyInfo[] assemblyFiles)
   at MonoDevelop.Core.Assemblies.AssemblyContext.RegisterPackage(MonoDevelop.Core.Assemblies.SystemPackageInfo pinfo, Boolean isInternal, System.String[] assemblyFiles)
   at MonoDevelop.Core.Assemblies.TargetRuntime.RegisterPackage(MonoDevelop.Core.Assemblies.SystemPackageInfo pinfo, Boolean isInternal, System.String[] assemblyFiles)
   at MonoDevelop.Core.Assemblies.TargetRuntime.RegisterPackage(MonoDevelop.Core.Assemblies.SystemPackageInfo pinfo, System.String[] assemblyFiles)
   at MonoDevelop.Core.Assemblies.TargetRuntime.OnPackagesChanged(System.Object s, Mono.Addins.ExtensionNodeEventArgs args)
   at Mono.Addins.ExtensionNode.add_ExtensionNodeChanged(Mono.Addins.ExtensionNodeEventHandler value)
   at Mono.Addins.ExtensionContext.AddExtensionNodeHandler(System.String path, Mono.Addins.ExtensionNodeEventHandler handler)
   at Mono.Addins.AddinManager.AddExtensionNodeHandler(System.String path, Mono.Addins.ExtensionNodeEventHandler handler)
   at MonoDevelop.Core.Assemblies.TargetRuntime.<RunInitialization>m__7(System.Object )
Comment 10 Lluis Sanchez 2012-05-18 08:07:25 UTC
I fixed this last issue in master. I can't tell for sure it fixes the original issue, since I could not reproduce, but I'm pretty sure it does. I'm closing the bug, if it happens again, feel free to reopen.
Comment 11 Mikayla Hutchinson [MSFT] 2012-05-18 13:21:50 UTC
Is this safe to backport for 3.0.2?
Comment 12 Mikayla Hutchinson [MSFT] 2012-05-18 19:24:48 UTC
I backported it anyway.

Here is a build that includes the fix. Rube and Scott, could you please verify that it fixes the issue for you?
http://files.xamarin.com/~mhutch/MonoDevelop-473059ab28c72278a9f5d8b23b34bca649c79dda.dmg
Comment 13 Mikayla Hutchinson [MSFT] 2012-05-18 19:25:51 UTC
Sorry, typo'ed "Ruben"...
Comment 14 shill 2012-05-18 23:54:05 UTC
The App in that DMG crashes when I try to launch it.

Console:

5/18/12 8:40:59 PM	com.apple.launchd.peruser.501[104]	([0x0-0x22022].com.ximian.monodevelop[327]) Job appears to have crashed: Segmentation fault


crash report:

Process:         mono [327]
Path:            /Applications/MonoDevelop.app/Contents/MacOS/bin/monodevelop
Identifier:      com.ximian.monodevelop
Version:         3.0.1 (3.0.1)
Code Type:       X86 (Native)
Parent Process:  launchd [104]

Date/Time:       2012-05-18 20:40:58.450 -0700
OS Version:      Mac OS X 10.6.8 (10K549)
Report Version:  6

Interval Since Last Report:          17346293 sec
Crashes Since Last Report:           107
Per-App Interval Since Last Report:  10535 sec
Per-App Crashes Since Last Report:   2
Anonymous UUID:                      783BC5BA-F760-4C9B-84A3-7CD5C6B8006F

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_PROTECTION_FAILURE at 0x00000000bf7ffffc
Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
0   monodevelop                   	0x0018666c mono_class_vtable_full + 12 (object.c:1776)
1   monodevelop                   	0x00187290 mono_class_vtable + 32 (object.c:1763)
2   monodevelop                   	0x001365e0 ves_icall_Type_GetFields_internal + 640 (icall.c:3435)
3   ???                           	0x14d31644 0 + 349378116
4   ???                           	0x14d315f8 0 + 349378040
Comment 15 Mikayla Hutchinson [MSFT] 2012-05-22 16:02:07 UTC
Is the crash reproducible? Is mdtool able to build your project?
Comment 16 shill 2012-05-22 16:03:47 UTC
The App in that DMG crashes when I try to launch it.
mdtool also crashes when I try to use.
Comment 17 Mikayla Hutchinson [MSFT] 2012-05-22 16:13:08 UTC
I can't reproduce the crash with that dmg. Can you please file a new bug with a full crash trace?
Comment 18 shill 2012-05-22 16:33:03 UTC
Created attachment 1945 [details]
MonoDevelop3.0.1CrashReport.txt

MonoDevelop 3.0.1 Crash Report is attached
Comment 19 Mikayla Hutchinson [MSFT] 2012-05-22 17:14:06 UTC
Thanks, unfortunately it looks like a stack overflow and Mono < 2.12 on MacOS doesn't print useful traces for those. We'll have to collect verbose logs to decode the stack frames.

Can you please open a terminal and run:
    export MONO_OPTIONS=-v
    /Applications/MonoDevelop.app/Contents/MacOS/monodevelop

Then attach the terminal output, the crash report, and the log from ~/Library/Logs/MonoDevelop-3.0/MonoDevelop.log
Comment 20 shill 2012-05-22 17:25:17 UTC
Created attachment 1946 [details]
Crash logs ZIP

ZIP is attached with the requested logs/output
Comment 21 Mikayla Hutchinson [MSFT] 2012-05-22 19:02:07 UTC
Thanks, I filed a new bug at 5254.