GNOME Bugzilla – Bug 573731
MonoDevelop debugging support
Last modified: 2010-02-13 22:52:28 UTC
MD 1.9.2 (AKA 2.0 beta 1) can debug mono projects, it would be great if Banshee could take advantage of this. Currently the breakpoints don't work when selecting Run/Debug (or hitting F5).
I wonder if the patch in bug 597950 fixes this issue.
please confirm.
I have been able to make some progress on this. It's available in a branch of my git clone on gitorious : http://gitorious.org/~bl8/banshee/bl8-clone/commits/monodevelop-debug I'm currently able to debug Banshee using mono 2.4.2.3 and MonoDevelop 2.2.1, but it hangs during startup, when loading webkit. I'd like to know if anyone has the same problem with other versions. By the way, some changes in the patch from bug 597950 do help for debugging, but there are other changes in the .csproj files needed.
Bertrand, that's good news. I wonder if the hang is a bug of the debugger, because with the last versions I've been getting lately an exception at startup when trying to load webkit, but the exception doesn't prevent me to run Banshee in the end. The stacktrace: [Debug 13:47:52.593] Adding context page wikipedia System.TypeInitializationException: An exception was thrown by the type initializer for WebKit.WebView ---> System.DllNotFoundException: webkit-1.0.so.1 at (wrapper managed-to-native) WebKit.WebHistoryItem:webkit_web_history_item_get_type () at WebKit.WebHistoryItem.get_GType () [0x00000] in <filename unknown>:0 at GtkSharp.WebkitSharp.ObjectManager.Initialize () [0x00000] in <filename unknown>:0 at WebKit.WebView..cctor () [0x00000] in <filename unknown>:0 --- End of inner exception stack trace --- at Banshee.Wikipedia.WikipediaView..ctor () [0x00016] in /home/knocte/Documentos/banshee/src/Extensions/Banshee.Wikipedia/Banshee.Wikipedia/WikipediaView.cs:54 at Banshee.Wikipedia.ContextPage.get_Widget () [0x0000b] in /home/knocte/Documentos/banshee/src/Extensions/Banshee.Wikipedia/Banshee.Wikipedia/ContextPage.cs:59 at Banshee.ContextPane.ContextPane.AddPage (Banshee.ContextPane.BaseContextPage page) [0x00038] in /home/knocte/Documentos/banshee/src/Core/Banshee.ThickClient/Banshee.ContextPane/ContextPane.cs:244 at Banshee.ContextPane.ContextPageManager.OnExtensionChanged (System.Object o, Mono.Addins.ExtensionNodeEventArgs args) [0x00023] in /home/knocte/Documentos/banshee/src/Core/Banshee.ThickClient/Banshee.ContextPane/ContextPageManager.cs:54 at Mono.Addins.ExtensionNode.add_ExtensionNodeChanged (Mono.Addins.ExtensionNodeEventHandler value) [0x00034] in /usr/src/packages/BUILD/mono-addins-0.4/Mono.Addins/Mono.Addins/ExtensionNode.cs:110 I guess it will go away if disabling the Wikipedia extension.
Andrés, I think your problem happens because your webkit-sharp.dll.config points to the wrong webkit-1.0.so file. See this commit : http://anonsvn.mono-project.com/viewvc?view=revision&revision=144155 So I don't think it's directly related to the debug problem.
Just tried your branch and debugging works! I could stop at breakpoints and step in/over. By the way, when debugging Banshee doesn't pick up the BANSHEE_DEV_OPTIONS environment variable.
(In reply to comment #6) > By the way, when debugging Banshee doesn't pick up the BANSHEE_DEV_OPTIONS > environment variable. After chatting with Bertrand on IRC, it appears to be the limitation of MD which doesn't expand the $(VAR) macros. Hardcoding it in Nereid project options (Run -> General) works. Relevant MD bug: https://bugzilla.novell.com/show_bug.cgi?id=404157
The sooner this gets into trunk the easier it'll be for people to contribute. Can someone please update this bug or create a blog entry for how exactly I'd setup MD to be able to debug Banshee. Keep up the good work.
Created attachment 153707 [details] [review] Allow debugging from MonoDevelop This patch contains the changes from my monodevelop-debug gitorious branch, against the latest master. The problem of not picking up the value of BANSHEE_DEV_OPTIONS is still there, but I think the gain of debugging outweighs this annoyance. So I'd be willing to commit this if people have no objections.
Looks good to me :) Thanks, Bertrand!
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.