Fixed
Status Update
Comments
ga...@google.com <ga...@google.com> #2
A stack trace for the exception would be useful to help confirm a theory I have about the cause for this. Or a full working code sample which can demonstrate the problem would allow us to investigate more easily.
es...@gmail.com <es...@gmail.com> #3
Here's a stack trace, crash happens right when an Ad is refreshed (changes) it seems ...
2017-06-02 10:01:00.876 Street-Browser[800:7958] Google Maps SDK for iOS version: 2.3.30035.0
2017-06-02 10:02:19.670 Street-Browser[800:8077] *** Terminating app due to uncaught exception 'GMSThreadException', reason: 'The API method must be called from the main thread'
*** First throw call stack:
(
0 CoreFoundation 0x00000001142f1b0b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x00000001136ba141 objc_exception_throw + 48
2 CoreFoundation 0x000000011435a625 +[NSException raise:format:] + 197
3 Street-Browser 0x000000010cdf3dae -[GMSPanoramaView camera] + 80
4 Street-Browser 0x000000010cdf535b -[GMSPanoramaView cameraDidChange:] + 42
5 Street-Browser 0x000000010cde7a79 -[GMSRocketIVGLView cameraDidUpdate:] + 100
6 Street-Browser 0x000000010cfec9ec -[GMSx_IVCameraLayer display] + 102
7 QuartzCore 0x00000001104eb31d _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 315
8 QuartzCore 0x00000001104eb3ab _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 35
9 QuartzCore 0x000000011047ae92 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294
10 QuartzCore 0x00000001104a7130 _ZN2CA11Transaction6commitEv + 468
11 QuartzCore 0x00000001104a7b37 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 115
12 CoreFoundation 0x0000000114297717 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
13 CoreFoundation 0x0000000114297687 __CFRunLoopDoObservers + 391
14 CoreFoundation 0x000000011427c720 __CFRunLoopRun + 1200
15 CoreFoundation 0x000000011427c016 CFRunLoopRunSpecific + 406
16 WebCore 0x000000011c663155 _ZL12RunWebThreadPv + 469
17 libsystem_pthread.dylib 0x0000000114ca993b _pthread_body + 180
18 libsystem_pthread.dylib 0x0000000114ca9887 _pthread_body + 0
19 libsystem_pthread.dylib 0x0000000114ca908d thread_start + 13
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb) bt
* thread #17, name = 'WebThread', stop reason = signal SIGABRT
* frame #0: 0x0000000114c74d42 libsystem_kernel.dylib`__pthread_kill + 10
frame #1: 0x0000000114cac457 libsystem_pthread.dylib`pthread_kill + 90
frame #2: 0x0000000114a0688f libsystem_c.dylib`abort + 127
frame #3: 0x00000001147f5ce5 libc++abi.dylib`abort_message + 245
frame #4: 0x0000000114810cbd libc++abi.dylib`default_terminate_handler() + 265
frame #5: 0x00000001136ba3c4 libobjc.A.dylib`_objc_terminate() + 103
frame #6: 0x000000011480df29 libc++abi.dylib`std::__terminate(void (*)()) + 8
frame #7: 0x000000011480dbbe libc++abi.dylib`__cxa_rethrow + 99
frame #8: 0x00000001136ba2dc libobjc.A.dylib`objc_exception_rethrow + 40
frame #9: 0x000000011427c096 CoreFoundation`CFRunLoopRunSpecific + 534
frame #10: 0x000000011c663155 WebCore`RunWebThread(void*) + 469
frame #11: 0x0000000114ca993b libsystem_pthread.dylib`_pthread_body + 180
frame #12: 0x0000000114ca9887 libsystem_pthread.dylib`_pthread_start + 286
frame #13: 0x0000000114ca908d libsystem_pthread.dylib`thread_start + 13
(lldb)
2017-06-02 10:01:00.876 Street-Browser[800:7958] Google Maps SDK for iOS version: 2.3.30035.0
2017-06-02 10:02:19.670 Street-Browser[800:8077] *** Terminating app due to uncaught exception 'GMSThreadException', reason: 'The API method must be called from the main thread'
*** First throw call stack:
(
0 CoreFoundation 0x00000001142f1b0b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x00000001136ba141 objc_exception_throw + 48
2 CoreFoundation 0x000000011435a625 +[NSException raise:format:] + 197
3 Street-Browser 0x000000010cdf3dae -[GMSPanoramaView camera] + 80
4 Street-Browser 0x000000010cdf535b -[GMSPanoramaView cameraDidChange:] + 42
5 Street-Browser 0x000000010cde7a79 -[GMSRocketIVGLView cameraDidUpdate:] + 100
6 Street-Browser 0x000000010cfec9ec -[GMSx_IVCameraLayer display] + 102
7 QuartzCore 0x00000001104eb31d _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 315
8 QuartzCore 0x00000001104eb3ab _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 35
9 QuartzCore 0x000000011047ae92 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294
10 QuartzCore 0x00000001104a7130 _ZN2CA11Transaction6commitEv + 468
11 QuartzCore 0x00000001104a7b37 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 115
12 CoreFoundation 0x0000000114297717 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
13 CoreFoundation 0x0000000114297687 __CFRunLoopDoObservers + 391
14 CoreFoundation 0x000000011427c720 __CFRunLoopRun + 1200
15 CoreFoundation 0x000000011427c016 CFRunLoopRunSpecific + 406
16 WebCore 0x000000011c663155 _ZL12RunWebThreadPv + 469
17 libsystem_pthread.dylib 0x0000000114ca993b _pthread_body + 180
18 libsystem_pthread.dylib 0x0000000114ca9887 _pthread_body + 0
19 libsystem_pthread.dylib 0x0000000114ca908d thread_start + 13
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb) bt
* thread #17, name = 'WebThread', stop reason = signal SIGABRT
* frame #0: 0x0000000114c74d42 libsystem_kernel.dylib`__pthread_kill + 10
frame #1: 0x0000000114cac457 libsystem_pthread.dylib`pthread_kill + 90
frame #2: 0x0000000114a0688f libsystem_c.dylib`abort + 127
frame #3: 0x00000001147f5ce5 libc++abi.dylib`abort_message + 245
frame #4: 0x0000000114810cbd libc++abi.dylib`default_terminate_handler() + 265
frame #5: 0x00000001136ba3c4 libobjc.A.dylib`_objc_terminate() + 103
frame #6: 0x000000011480df29 libc++abi.dylib`std::__terminate(void (*)()) + 8
frame #7: 0x000000011480dbbe libc++abi.dylib`__cxa_rethrow + 99
frame #8: 0x00000001136ba2dc libobjc.A.dylib`objc_exception_rethrow + 40
frame #9: 0x000000011427c096 CoreFoundation`CFRunLoopRunSpecific + 534
frame #10: 0x000000011c663155 WebCore`RunWebThread(void*) + 469
frame #11: 0x0000000114ca993b libsystem_pthread.dylib`_pthread_body + 180
frame #12: 0x0000000114ca9887 libsystem_pthread.dylib`_pthread_start + 286
frame #13: 0x0000000114ca908d libsystem_pthread.dylib`thread_start + 13
(lldb)
es...@gmail.com <es...@gmail.com> #4
Update: It also happens when Panorama view isn't visible, just a mapView and a Google Ad.
It seems rotating the simulator screen a couple times is enough to trigger a crash.
It seems rotating the simulator screen a couple times is enough to trigger a crash.
ga...@google.com <ga...@google.com> #5
Stack trace confirms my theory - can you confirm whether your second crash scenario has the same stack trace?
es...@gmail.com <es...@gmail.com> #6
Yes, both scenarios look almost identical, the only difference is this line is missing without Panorama :
14 CoreFoundation 0x000000010ae11720 __CFRunLoopRun + 1200
*** First throw call stack:
(
0 CoreFoundation 0x000000010ae86b0b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x000000010a248141 objc_exception_throw + 48
2 CoreFoundation 0x000000010aeef625 +[NSException raise:format:] + 197
3 Street-Browser 0x0000000103a31dae -[GMSPanoramaView camera] + 80
4 Street-Browser 0x0000000103a3335b -[GMSPanoramaView cameraDidChange:] + 42
5 Street-Browser 0x0000000103a25a79 -[GMSRocketIVGLView cameraDidUpdate:] + 100
6 Street-Browser 0x0000000103c2a9ec -[GMSx_IVCameraLayer display] + 102
7 QuartzCore 0x000000010707431d _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 315
8 QuartzCore 0x00000001070743ab _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 35
9 QuartzCore 0x0000000107003e92 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294
10 QuartzCore 0x0000000107030130 _ZN2CA11Transaction6commitEv + 468
11 QuartzCore 0x0000000107030b37 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 115
12 CoreFoundation 0x000000010ae2c717 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
13 CoreFoundation 0x000000010ae2c687 __CFRunLoopDoObservers + 391
14 CoreFoundation 0x000000010ae11720 __CFRunLoopRun + 1200
15 CoreFoundation 0x000000010ae11016 CFRunLoopRunSpecific + 406
16 WebCore 0x00000001132a7155 _ZL12RunWebThreadPv + 469
17 libsystem_pthread.dylib 0x000000010b85893b _pthread_body + 180
18 libsystem_pthread.dylib 0x000000010b858887 _pthread_body + 0
19 libsystem_pthread.dylib 0x000000010b85808d thread_start + 13
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb) bt
* thread #17, name = 'WebThread', stop reason = signal SIGABRT
* frame #0: 0x000000010b823d42 libsystem_kernel.dylib`__pthread_kill + 10
frame #1: 0x000000010b85b457 libsystem_pthread.dylib`pthread_kill + 90
frame #2: 0x000000010b5b588f libsystem_c.dylib`abort + 127
frame #3: 0x000000010b38ace5 libc++abi.dylib`abort_message + 245
frame #4: 0x000000010b3a5cbd libc++abi.dylib`default_terminate_handler() + 265
frame #5: 0x000000010a2483c4 libobjc.A.dylib`_objc_terminate() + 103
frame #6: 0x000000010b3a2f29 libc++abi.dylib`std::__terminate(void (*)()) + 8
frame #7: 0x000000010b3a2bbe libc++abi.dylib`__cxa_rethrow + 99
frame #8: 0x000000010a2482dc libobjc.A.dylib`objc_exception_rethrow + 40
frame #9: 0x000000010ae11096 CoreFoundation`CFRunLoopRunSpecific + 534
frame #10: 0x00000001132a7155 WebCore`RunWebThread(void*) + 469
frame #11: 0x000000010b85893b libsystem_pthread.dylib`_pthread_body + 180
frame #12: 0x000000010b858887 libsystem_pthread.dylib`_pthread_start + 286
frame #13: 0x000000010b85808d libsystem_pthread.dylib`thread_start + 13
(lldb)
14 CoreFoundation 0x000000010ae11720 __CFRunLoopRun + 1200
*** First throw call stack:
(
0 CoreFoundation 0x000000010ae86b0b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x000000010a248141 objc_exception_throw + 48
2 CoreFoundation 0x000000010aeef625 +[NSException raise:format:] + 197
3 Street-Browser 0x0000000103a31dae -[GMSPanoramaView camera] + 80
4 Street-Browser 0x0000000103a3335b -[GMSPanoramaView cameraDidChange:] + 42
5 Street-Browser 0x0000000103a25a79 -[GMSRocketIVGLView cameraDidUpdate:] + 100
6 Street-Browser 0x0000000103c2a9ec -[GMSx_IVCameraLayer display] + 102
7 QuartzCore 0x000000010707431d _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 315
8 QuartzCore 0x00000001070743ab _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 35
9 QuartzCore 0x0000000107003e92 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294
10 QuartzCore 0x0000000107030130 _ZN2CA11Transaction6commitEv + 468
11 QuartzCore 0x0000000107030b37 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 115
12 CoreFoundation 0x000000010ae2c717 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
13 CoreFoundation 0x000000010ae2c687 __CFRunLoopDoObservers + 391
14 CoreFoundation 0x000000010ae11720 __CFRunLoopRun + 1200
15 CoreFoundation 0x000000010ae11016 CFRunLoopRunSpecific + 406
16 WebCore 0x00000001132a7155 _ZL12RunWebThreadPv + 469
17 libsystem_pthread.dylib 0x000000010b85893b _pthread_body + 180
18 libsystem_pthread.dylib 0x000000010b858887 _pthread_body + 0
19 libsystem_pthread.dylib 0x000000010b85808d thread_start + 13
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb) bt
* thread #17, name = 'WebThread', stop reason = signal SIGABRT
* frame #0: 0x000000010b823d42 libsystem_kernel.dylib`__pthread_kill + 10
frame #1: 0x000000010b85b457 libsystem_pthread.dylib`pthread_kill + 90
frame #2: 0x000000010b5b588f libsystem_c.dylib`abort + 127
frame #3: 0x000000010b38ace5 libc++abi.dylib`abort_message + 245
frame #4: 0x000000010b3a5cbd libc++abi.dylib`default_terminate_handler() + 265
frame #5: 0x000000010a2483c4 libobjc.A.dylib`_objc_terminate() + 103
frame #6: 0x000000010b3a2f29 libc++abi.dylib`std::__terminate(void (*)()) + 8
frame #7: 0x000000010b3a2bbe libc++abi.dylib`__cxa_rethrow + 99
frame #8: 0x000000010a2482dc libobjc.A.dylib`objc_exception_rethrow + 40
frame #9: 0x000000010ae11096 CoreFoundation`CFRunLoopRunSpecific + 534
frame #10: 0x00000001132a7155 WebCore`RunWebThread(void*) + 469
frame #11: 0x000000010b85893b libsystem_pthread.dylib`_pthread_body + 180
frame #12: 0x000000010b858887 libsystem_pthread.dylib`_pthread_start + 286
frame #13: 0x000000010b85808d libsystem_pthread.dylib`thread_start + 13
(lldb)
es...@gmail.com <es...@gmail.com> #7
Just wondering what your theory was?
Is there something I can do to fix in my code or wait for SDK update?
Is there something I can do to fix in my code or wait for SDK update?
di...@google.com <di...@google.com>
ga...@google.com <ga...@google.com> #8
This issue is fixed in iOS Maps SDK 2.3.1. Please give it a try.
For reference the underlying problem is possibly a bug in iOS - when you have a UIWebView in the view hierarchy at the same time as another view which uses a custom CALayer, the display callback for the custom CALayer sometimes spontaneously changes to be called on the web thread rather than the main thread.
For reference the underlying problem is possibly a bug in iOS - when you have a UIWebView in the view hierarchy at the same time as another view which uses a custom CALayer, the display callback for the custom CALayer sometimes spontaneously changes to be called on the web thread rather than the main thread.
es...@gmail.com <es...@gmail.com> #9
Confirmed, the issue is now fixed.
Thank you.
Thank you.
ve...@amt.in <ve...@amt.in> #10
Hi
Can anybody help
I am facing the below issue in iOS , how to resolve...?
Binary file ./Pods/Crashlytics/iOS/Crashlytics.framework/Crashlytics matches
./Pods/GoogleMaps/CHANGELOG: - Fixed an issue resulting in a crash when UIWebView and GMSPanoramaView are
./Pods/GoogleMaps/CHANGELOG: - Fixed a crash when using both a GMSMapView and a UIWebView or WKWebView in the view
Can anybody help
I am facing the below issue in iOS , how to resolve...?
Binary file ./Pods/Crashlytics/iOS/Crashlytics.framework/Crashlytics matches
./Pods/GoogleMaps/CHANGELOG: - Fixed an issue resulting in a crash when UIWebView and GMSPanoramaView are
./Pods/GoogleMaps/CHANGELOG: - Fixed a crash when using both a GMSMapView and a UIWebView or WKWebView in the view
Description
# It is OK to share your API Project ID, but _not_ API keys.
Issue report
----------------
Steps to reproduce the problem:
1. Load a mapView, then show a panorama.
2. Wait a few seconds after it loads and crash ...
Please note that this is on an existing project of mine,
which was recently updated from SDK 2.2 to 2.3 and there
were no issues using SDK 2.2, however Google Mobile Ads
was also update to 7.20 from 7.19 and now the crash happens
100% of time while displaying a panorama with an active Ad.
When Ads are disabled, there is no issues.
This did not happen using SDK 2.2
Error is "GMSThreadException The API method must be called from the main thread"
but I do not perform any API calls from background threads in my code.
Current version based on SDK 2.2 that runs without issues, source unchanged:
Link to the Demo application[1] that reproduces the problem:
Operating system version: MacOS Sierra
Google Maps SDK for iOS version: 2.3
Hardware model: Simulator IOS 10
-------------------------------------------------------------------
[1] You can fork