Bug 55446 - Google Maps crash
Summary: Google Maps crash
Alias: None
Product: Android
Classification: Xamarin
Component: Android+BCL Integration ()
Version: 7.1 (C9)
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Marek Habersack
Depends on:
Reported: 2017-04-21 09:12 UTC by anton.duzenko@gmail.com
Modified: 2017-10-04 17:25 UTC (History)
2 users (show)

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

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:

Description anton.duzenko@gmail.com 2017-04-21 09:12:12 UTC
Package: com.smartwebs.xp
Version Code: 82
Version Name: 1.0.82
Android: 6.0.1
Android Build: MMB29K.J320AUCU1APC9
Manufacturer: samsung
Thread: main-1
CrashReporter Key: 42B0CEE7-0F5F-F017-A8ED-E6D1B513C0A2FAEF6436
Start Date: Thu Mar 23 11:35:57 MDT 2017
Date: Thu Mar 23 11:36:18 MDT 2017
Format: Xamarin

Xamarin caused by: android.runtime.JavaProxyThrowable: System.NotSupportedException: Unable to activate instance of type SmartwebsCrossPlatform.Android.CustomRenderers.CustomMapRenderer from native handle 0xbebb3e2c (key_handle 0xb50ff89). ---> System.MissingMethodException: No constructor found for SmartwebsCrossPlatform.Android.CustomRenderers.CustomMapRenderer::.ctor(System.IntPtr, Android.Runtime.JniHandleOwnership) ---> Java.Interop.JavaLocationException: Exception of type 'Java.Interop.JavaLocationException' was thrown.
   --- End of inner exception stack trace ---
  at Java.Interop.TypeManager.CreateProxy (System.Type type, System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer) [0x00058] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Java.Interop.TypeManager.CreateInstance (System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer, System.Type targetType) [0x00138] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
   --- End of inner exception stack trace ---
  at Java.Interop.TypeManager.CreateInstance (System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer, System.Type targetType) [0x001b0] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Java.Lang.Object.GetObject (System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer, System.Type type) [0x000e5] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Java.Lang.Object._GetObject[T] (System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer) [0x0001a] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Java.Lang.Object.GetObject[T] (System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer) [0x00000] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Java.Lang.Object.GetObject[T] (System.IntPtr jnienv, System.IntPtr handle, Android.Runtime.JniHandleOwnership transfer) [0x00006] in <253a5f5d3f134a8eaf18f448fae86b2c>:0 
  at Android.Gms.Maps.GoogleMap+IOnCameraChangeListenerInvoker.n_OnCameraChange_Lcom_google_android_gms_maps_model_CameraPosition_ (System.IntPtr jnienv, System.IntPtr native__this, System.IntPtr native_position) [0x00000] in <cede2ee4138a48bb98b62dcaee115663>:0 
  at (wrapper dynamic-method) System.Object:afc9ad44-ca7c-447e-8a88-2518ccaf9399 (intptr,intptr,intptr)
	at md5d956392b2b421ac2c9ccfc063253dcd9.MapRenderer.n_onCameraChange(Native Method)
	at md5d956392b2b421ac2c9ccfc063253dcd9.MapRenderer.onCameraChange(MapRenderer.java:55)
	at com.google.android.gms.maps.GoogleMap$12.onCameraChange(Unknown Source)
	at com.google.android.gms.maps.internal.zze$zza.onTransact(Unknown Source)
	at android.os.Binder.transact(Binder.java:387)
	at com.google.android.gms.maps.internal.ad.a(:com.google.android.gms.DynamiteModulesB:93)
	at com.google.maps.api.android.lib6.gmm6.api.a.b(:com.google.android.gms.DynamiteModulesB:246)
	at com.google.maps.api.android.lib6.gmm6.api.b.run(:com.google.android.gms.DynamiteModulesB:2037)
	at android.os.Handler.handleCallback(Handler.java:739)
	at android.os.Handler.dispatchMessage(Handler.java:95)
	at android.os.Looper.loop(Looper.java:158)
	at android.app.ActivityThread.main(ActivityThread.java:7230)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Comment 1 Marek Habersack 2017-04-21 12:52:23 UTC
Could you provide a small app which reproduces the issue? It's impossible to diagnose it based solely on the provided stack trace. Thanks!
Comment 2 anton.duzenko@gmail.com 2017-04-23 19:29:20 UTC
I can't repeat this on demand.
This happens on user's device and developer console report is all I have.
Comment 3 Marek Habersack 2017-04-24 14:42:13 UTC
@Anton, can you change your GC bridge as described https://bugzilla.xamarin.com/show_bug.cgi?id=51651#c2 and see if that helps the user who's getting the exception?
Comment 4 anton.duzenko@gmail.com 2017-04-24 14:52:40 UTC
Change my GC bridge to what value?
As for user I don't know if they're still using the app or have uninstalled it already because of all the crashes
Comment 5 anton.duzenko@gmail.com 2017-04-24 14:53:26 UTC
Can you provide any explanation on this particular crash - what does it mean and why does it happen at all?
Comment 6 Marek Habersack 2017-04-24 14:57:17 UTC
@anton Change the GC bridge to the one you're not currently using (as per https://developer.xamarin.com/guides/android/advanced_topics/garbage_collection/#GC_Bridge_Options). We don't know what the crash means, we suspect it has to do with the GC bridge in that it loses synchronization between the .NET and Java garbage collectors - hence the request to try another GC bridge. 

Another option is that there's a premature .Dispose() call on one of your objects (on the .NET side)

However there's not enough data for us to really know what's going on at this point.
Comment 7 Jon Douglas [MSFT] 2017-10-04 17:25:37 UTC
Because we have not received a reply to our request for more information we are closing this issue. If you are still encountering this issue, please reopen the ticket with the requested information. Thanks!