Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
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
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.
Since Xamarin.Android 5.0 unhandled exceptions behaviour is different. Unhandled exception is caught in Java and then rethrown as unhandled exception. Problem is that runtime is not stopped where exception was thrown but at this stacktrace:
Imo XS can't do this for 2 reasons:
1. XS doesn't have location, because XS opens at location where runtime is stopped and this location is received via sdb protocol. This could very hackishy worked around by parsing exception stacktrace and if it finds location in user code, it opens at that location.(not super robust)
2. Real problem imo... User should be able to evaluate variables in method where exception was thrown, so even if we work around 1. problem user still won't be able to evaluate state in which exception was thrown. This is unacceptable imo.
*** Bug 31050 has been marked as a duplicate of this bug. ***
I still have this issue.
The fixes for this issue are now slated for our Cycle 6 release, which will come out early in the fall.
is xamarin retiring xamarin studio in windows in favor of visual studio plugin ?
how we are supposed to debug software while debugger is not working and you are giving a three month estimate , 3 months after issue submission ?
This behaviour is same on OSX and Windows.
Also VisualStudio plugin has same problem with unhanded exceptions on Android. Problem is new way exceptions in Xamarin.Android are handled that is much better overall but has problem with displaying unhanded exceptions when attached with debugger...
in what way it's better?
I put a button with throw(new Exception ("test exception")); on click ,
the debugger won't break on the line and below is what the debugger shows,
how it can help to debug exceptions when the inner exception is not shown at all?
at --- End of managed exception stack trace ---
at java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
at at dalvik.system.NativeStart.main(Native Method)
at Caused by: java.lang.reflect.InvocationTargetException
at at java.lang.reflect.Method.invokeNative(Native Method)
at at java.lang.reflect.Method.invoke(Method.java:515)
at at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
at ... 2 more
at Caused by: md52ce486a14f4bcd95899665e9d932190b.JavaProxyThrowable: System.Exception: test exception
at at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () <IL 0x00011, 0x0004b>
at at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<ThrowAsync>m__0 (object) <IL 0x00006, 0x0003b>
at Android.App.SyncContext/<Post>c__AnonStorey0.<>m__0 () [0x00000] in /Users/builder/data/lanes/1879/5f55a9ef/source/monodroid/src/Mono.Android/src/Android.App/SyncContext.cs:18
at Java.Lang.Thread/RunnableImplementor.Run () [0x0000b] in /Users/builder/data/lanes/1879/5f55a9ef/source/monodroid/src/Mono.Android/src/Java.Lang/Thread.cs:36
at Java.Lang.IRunnableInvoker.n_Run (intptr,intptr) [0x00009] in /Users/builder/data/lanes/1879/5f55a9ef/source/monodroid/src/Mono.Android/platforms/android-21/src/generated/Java.Lang.IRunnable.cs:71
at at (wrapper dynamic-method) object.e262e51d-d744-4292-8325-804790506276 (intptr,intptr) <IL 0x00011, 0x0001f>
at at mono.java.lang.RunnableImplementor.n_run(Native Method)
at at mono.java.lang.RunnableImplementor.run(RunnableImplementor.java:29)
at at android.os.Handler.handleCallback(Handler.java:733)
at at android.os.Handler.dispatchMessage(Handler.java:95)
at at android.os.Looper.loop(Looper.java:136)
at at android.app.ActivityThread.main(ActivityThread.java:5017)
at ... 5 more
This was fixed in Xamarin.Android master. Fix will be part of XA 5.2 series aka. Cycle 6.
*** Bug 29818 has been marked as a duplicate of this bug. ***
*** Bug 32360 has been marked as a duplicate of this bug. ***
I have checked this issue and its working fine.
Hence closing this issue.
=== Xamarin Studio ===
Version 5.10 (build 811)
Installation UUID: 1a096c6f-0678-402e-89b2-a2c10f7e80e4
Mono 4.2.1 (explicit/cc1cf60)
GTK+ 2.24.23 (Raleigh theme)
Package version: 402010062
=== Xamarin.Profiler ===
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler
=== Apple Developer Tools ===
Xcode 7.0 (8227)
=== Xamarin.Mac ===
Version: 188.8.131.52 (Enterprise Edition)
=== Xamarin.Android ===
Version: 184.108.40.206 (Enterprise Edition)
Android SDK: /Users/360_macmini/Desktop/android-sdk-macosx
Supported Android versions:
2.3 (API level 10)
4.0.3 (API level 15)
4.1 (API level 16)
4.2 (API level 17)
4.3 (API level 18)
4.4 (API level 19)
4.4.87 (API level 20)
5.0 (API level 21)
5.1 (API level 22)
6.0 (API level 23)
SDK Tools Version: 24.3.4
SDK Platform Tools Version: 23.0.1
SDK Build Tools Version: 23.0.1
Java SDK: /usr
java version "1.8.0_31"
Java(TM) SE Runtime Environment (build 1.8.0_31-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.31-b07, mixed mode)
=== Xamarin Android Player ===
Location: /Applications/Xamarin Android Player.app
=== Xamarin.iOS ===
Version: 220.127.116.11 (Enterprise Edition)
Build date: 2015-09-30 15:22:15-0400
=== Build Information ===
Release ID: 510000811
Git revision: 34cd31ea72536afab530c14d9220b286075e83cd
Build date: 2015-09-30 10:40:37-04
Xamarin addins: 8e6fccfc0c19a7e0b7b11be925f09751d827eb5c
Build lane: monodevelop-lion-cycle6
=== Operating System ===
Mac OS X 10.10.5
Darwin ShrutiMac.local 14.5.0 Darwin Kernel Version 14.5.0
Wed Jul 29 02:26:53 PDT 2015