amay077 / Xamarin.Forms.GoogleMaps

Map library for Xamarin.Forms using Google maps API
https://www.nuget.org/packages/Xamarin.Forms.GoogleMaps/
MIT License
546 stars 346 forks source link

Crash on iOS caused by Xamarin.Forms.GoogleMaps.iOS.MapRenderer.LayoutSubviews () #610

Open svilupposoftwarepharmaidea opened 5 years ago

svilupposoftwarepharmaidea commented 5 years ago

BUG / PROBLEM REPORT SUMMARY I received on my CrashReporter (HockeyApp) a lot of random crashes from multiple users. I wasn't able to reproduce it. The scenario is a view that shows a list of records. Users can switch from list mode to map mode and vice versa. There is possibility, that it may happen while users (in map mode) put the app in background and then reopen it. But this is only my guess.

VERSIONS Xamarin.Forms.GoogleMaps - 2.3.0 Xamarin.Forms - 3.1.0.697729 Xamarin.Google.iOS.Maps - 2.5.0

PLATFORM AFFECTED iOS

HOW TO REPRODUCE I wasn't able to reproduce it, however I received on CrashReporter (HockeyApp) a lot of crashes with call stack similar to the following:

Exception Type: SIGABRT Exception Codes: #0 at 0x1a8d1acc Crashed Thread: 0

Application Specific Information:
*** Terminating app due to uncaught exception 'System.NullReferenceException', reason: 'System.NullReferenceException: Object reference not set to an instance of an object'

Xamarin Exception Stack:
  at Xamarin.Forms.GoogleMaps.iOS.MapRenderer.LayoutSubviews () <0x1896185 + 0x00059> in <b439fe4f855441998b3193eab2858934#bc9c870a4a9238267685a8e4afb2e826>:0 
  at (wrapper managed-to-native) ObjCRuntime.Messaging.objc_msgSend(intptr,intptr)
  at CoreAnimation.CALayer.LayoutSublayers () <0xb4cde1 + 0x00014> in <e3c114529df74463846bdbf53ad88be0#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementTracker+<>c__DisplayClass23_0.<OnUpdateNativeControl>b__0 () <0xd2e1b9 + 0x00240> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementTracker.OnUpdateNativeControl (CoreAnimation.CALayer caLayer) <0xd0f365 + 0x00364> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementTracker.UpdateNativeControl () <0xd0f77d + 0x00088> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementTracker.SetElement (Xamarin.Forms.VisualElement oldElement, Xamarin.Forms.VisualElement newElement) <0xd0f711 + 0x00066> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementTracker..ctor (Xamarin.Forms.Platform.iOS.IVisualElementRenderer renderer) <0xd0ee2d + 0x00160> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].SetElement (TElement_REF element) <0xd0e319 + 0x0019c> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].Xamarin.Forms.Platform.iOS.IVisualElementRenderer.SetElement (Xamarin.Forms.VisualElement element) <0xd0e171 + 0x00022> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.Platform.CreateRenderer (Xamarin.Forms.VisualElement element) <0xd0a811 + 0x00052> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.OnChildAdded (Xamarin.Forms.VisualElement view) <0xd0d83d + 0x00074> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.Load () <0xd0d669 + 0x00072> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].SetElement (TElement_REF element) <0xd0e319 + 0x00246> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].Xamarin.Forms.Platform.iOS.IVisualElementRenderer.SetElement (Xamarin.Forms.VisualElement element) <0xd0e171 + 0x00022> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.Platform.CreateRenderer (Xamarin.Forms.VisualElement element) <0xd0a811 + 0x00052> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.OnChildAdded (Xamarin.Forms.VisualElement view) <0xd0d83d + 0x00074> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.Load () <0xd0d669 + 0x00072> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].SetElement (TElement_REF element) <0xd0e319 + 0x00246> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].Xamarin.Forms.Platform.iOS.IVisualElementRenderer.SetElement (Xamarin.Forms.VisualElement element) <0xd0e171 + 0x00022> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.Platform.CreateRenderer (Xamarin.Forms.VisualElement element) <0xd0a811 + 0x00052> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.OnChildAdded (Xamarin.Forms.VisualElement view) <0xd0d83d + 0x00074> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.Load () <0xd0d669 + 0x00072> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].SetElement (TElement_REF element) <0xd0e319 + 0x00246> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementRenderer`1[TElement].Xamarin.Forms.Platform.iOS.IVisualElementRenderer.SetElement (Xamarin.Forms.VisualElement element) <0xd0e171 + 0x00022> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.Platform.CreateRenderer (Xamarin.Forms.VisualElement element) <0xd0a811 + 0x00052> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.OnChildAdded (Xamarin.Forms.VisualElement view) <0xd0d83d + 0x00074> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.VisualElementPackager.Load () <0xd0d669 + 0x00072> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.PageRenderer.ViewDidLoad () <0xd1fbf5 + 0x0015c> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at (wrapper managed-to-native) ObjCRuntime.Messaging.objc_msgSendSuper(intptr,intptr)
  at UIKit.UIViewController.get_View () <0xb61c65 + 0x00038> in <e3c114529df74463846bdbf53ad88be0#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.PageRenderer.SetElement (Xamarin.Forms.VisualElement element) <0xd1f8c9 + 0x0008a> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.Platform.CreateRenderer (Xamarin.Forms.VisualElement element) <0xd0a811 + 0x00052> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.NavigationRenderer.CreateViewControllerForPage (Xamarin.Forms.Page page) <0xd1df21 + 0x00026> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Xamarin.Forms.Platform.iOS.NavigationRenderer+<OnPushAsync>d__47.MoveNext () <0xd33695 + 0x00022> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
--- End of stack trace from previous location where exception was thrown ---
  at Xamarin.Forms.Platform.iOS.NavigationRenderer+<<ViewDidLoad>b__42_0>d.MoveNext () <0xce49a4 + 0x00173> in <2dda3b1bfacd483c96a064e61838cf65#bc9c870a4a9238267685a8e4afb2e826>:0 
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__6_0 (System.Object state) <0x395c05 + 0x00031> in <01f05773bcda4d0b9642de54d8f3cec3#bc9c870a4a9238267685a8e4afb2e826>:0 
  at Foundation.NSAsyncSynchronizationContextDispatcher.Apply () <0xb74dad + 0x00014> in <e3c114529df74463846bdbf53ad88be0#bc9c870a4a9238267685a8e4afb2e826>:0 
  at (wrapper managed-to-native) UIKit.UIApplication.UIApplicationMain(int,string[],intptr,intptr)
  at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) <0xb50e4d + 0x0006a> in <e3c114529df74463846bdbf53ad88be0#bc9c870a4a9238267685a8e4afb2e826>:0 
  at PharmaIdea.Rea.Mobile.iOS.Application.Main (System.String[] args) <0x1a45b5 + 0x00052> in <8fa91b32151a4e8896e0bb3290b4193a#bc9c870a4a9238267685a8e4afb2e826>:0