Luca Corradi
Luca Corradi

Reputation: 2141

iOS crash in release after update GoogleMaps and GooglePlaces pods

I have an objective-c app that uses GoogleMaps and GooglePlaces pods, version 2.7.0 until now. Due to recent deprecations Google is asking to upgrade to v3.0.0 for both. https://developers.google.com/places/ios-sdk/client-migration

The Problem

When I edit the app to use the versions 3.0.0, it crashes just after the LaunchScreen without calling delegate's didFinishLaunchingWithOptions. That happens only in Release configuration, and only with physical devices.

#0  0x00000001014d5290 in std::__1::vector<int, std::__1::allocator<int> >::vector(std::__1::vector<int, std::__1::allocator<int> > const&) ()
#1  0x0000000101633178 in std::__1::vector<unsigned int, std::__1::allocator<unsigned int> >::vector(unsigned long) ()
#2  0x0000000101683494 in GMSx_absl::base_internal::InitGetTID() ()
#3  0x000000010167ae38 in void GMSx_absl::base_internal::CallOnceImpl<void (&)()>(std::__1::atomic<unsigned int>*, GMSx_absl::base_internal::SchedulingMode, void (&&&)()) ()
#4  0x00000001016833c4 in GMSx_absl::base_internal::GetTID() ()
#5  0x00000001016566a0 in GMSx_base_logging::LogMessage::Flush() ()
#6  0x00000001016564d4 in GMSx_base_logging::LogMessage::~LogMessage() ()
#7  0x0000000101655290 in (anonymous namespace)::AddFlagValidator(void const*, bool (*)()) ()
#8  0x00000001016841d0 in _GLOBAL__sub_I_vlog_is_on.cc ()
#9  0x0000000102649504 in ImageLoaderMachO::doModInitFunctions(ImageLoader::LinkContext const&) ()
#10 0x0000000102649738 in ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&) ()
#11 0x0000000102644768 in ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()
#12 0x0000000102643798 in ImageLoader::processInitializers(ImageLoader::LinkContext const&, unsigned int, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()
#13 0x0000000102643854 in ImageLoader::runInitializers(ImageLoader::LinkContext const&, ImageLoader::InitializerTimingList&) ()
#14 0x00000001026326a4 in dyld::initializeMainExecutable() ()
#15 0x0000000102637468 in dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) ()
#16 0x0000000102631044 in _dyld_start ()

Symbols dump

<_NSCallStackArray 0x104f67740>(
0   ???                                 0x00000001050f890c 0x0 + 4379871500,
1   MyApp                              0x00000001010416e0 main + 0,
2   MyApp                              0x0000000101683494 _ZN9GMSx_absl13base_internalL10InitGetTIDEv + 116,
3   MyApp                              0x000000010167ae38 _ZN9GMSx_absl13base_internal12CallOnceImplIRFvvEJEEEvPNSt3__16atomicIjEENS0_14SchedulingModeEOT_DpOT0_ + 88,
4   MyApp                              0x00000001016833c4 _ZN9GMSx_absl13base_internal6GetTIDEv + 420,
5   MyApp                              0x00000001016566a0 _ZN17GMSx_base_logging10LogMessage5FlushEv + 280,
6   MyApp                              0x00000001016564d4 _ZN17GMSx_base_logging10LogMessageD2Ev + 20,
7   MyApp                              0x0000000101655290 _ZN12_GLOBAL__N_116AddFlagValidatorEPKvPFbvE + 316,
8   MyApp                              0x00000001016841d0 _GLOBAL__sub_I_vlog_is_on.cc + 56,
9   ???                                 0x0000000102649504 0x0 + 4335113476,
10  ???                                 0x0000000102649738 0x0 + 4335114040,
11  ???                                 0x0000000102644768 0x0 + 4335093608,
12  ???                                 0x0000000102643798 0x0 + 4335089560,
13  ???                                 0x0000000102643854 0x0 + 4335089748,
14  ???                                 0x00000001026326a4 0x0 + 4335019684,
15  ???                                 0x0000000102637468 0x0 + 4335039592,
16  ???                                 0x0000000102631044 0x0 + 4335013956
)

What I tried so far

Just to ensure it's not a 'fake error':

But I also tried these workarounds:

Nothing of the above did solve or skip the crash. Restoring the versions back to 2.7.0 makes the app working again!

Did anybody experienced something similar with GoogleMaps and GooglePaces libraries? Can anybody suggest another way to investigate the problem?

Solution

Version 3.0.3 of the pods solve the error

Upvotes: 5

Views: 1133

Answers (1)

G&#246;khan Sayılgan
G&#246;khan Sayılgan

Reputation: 164

Cocoapods would fail if versions are not matching, to solve;

open up terminal and;

  sudo gem install cocoapods

Add --pre to get the latest pre release:

  sudo gem install cocoapods --pre

Upvotes: 0

Related Questions