firebase-ios-sdk: App crashes in Release mode while logging App start session event
Description
App works fine in Debug
mode but crashes in Release
mode upon App launch while logging App start session event.
Reproducing the issue
We are observing this issue when using Bazel(https://bazel.build/) build system hence the Demo project is also built using Bazel.
To reproduce.
Clone this repo - https://github.com/sanju-naik/bazel-demo-github , and checkout firebase-sessions-crash-in-opt
branch.
- Install bazelisk
brew install bazelisk
- From the cloned repo, cd’into
BazelDemo
and runbazel run //:BazelDemo_gen
to generate project. - open
BazelDemo.xcodeproj
and buildBazelDemo-Release
scheme you would notice crash as attached in above screenshot.
Firebase SDK Version
10.7.0
Xcode Version
14.3
Installation Method
CocoaPods
Firebase Product(s)
Analytics, Crashlytics, Performance
Targeted Platforms
iOS
Relevant Log Output
No response
If using Swift Package Manager, the project’s Package.resolved
Expand Package.resolved
snippet
Replace this line with the contents of your Package.resolved.
If using CocoaPods, the project’s Podfile.lock
Expand Podfile.lock
snippet
PODS:
- Alamofire (5.6.4)
- Firebase (10.7.0):
- Firebase/Core (= 10.7.0)
- Firebase/Core (10.7.0):
- Firebase/CoreOnly
- FirebaseAnalytics (~> 10.7.0)
- Firebase/CoreOnly (10.7.0):
- FirebaseCore (= 10.7.0)
- FirebaseABTesting (10.10.0):
- FirebaseCore (~> 10.0)
- FirebaseAnalytics (10.7.0):
- FirebaseAnalytics/AdIdSupport (= 10.7.0)
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- GoogleUtilities/Network (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- nanopb (< 2.30910.0, >= 2.30908.0)
- FirebaseAnalytics/AdIdSupport (10.7.0):
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleAppMeasurement (= 10.7.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- GoogleUtilities/Network (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- nanopb (< 2.30910.0, >= 2.30908.0)
- FirebaseCore (10.7.0):
- FirebaseCoreInternal (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/Logger (~> 7.8)
- FirebaseCoreExtension (10.10.0):
- FirebaseCore (~> 10.0)
- FirebaseCoreInternal (10.10.0):
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseCrashlytics (10.7.0):
- FirebaseCore (~> 10.5)
- FirebaseInstallations (~> 10.0)
- FirebaseSessions (~> 10.5)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.8)
- nanopb (< 2.30910.0, >= 2.30908.0)
- PromisesObjC (~> 2.1)
- FirebaseDynamicLinks (10.7.0):
- FirebaseCore (~> 10.0)
- FirebaseInstallations (10.10.0):
- FirebaseCore (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- PromisesObjC (~> 2.1)
- FirebasePerformance (10.7.0):
- FirebaseCore (~> 10.5)
- FirebaseInstallations (~> 10.0)
- FirebaseRemoteConfig (~> 10.0)
- FirebaseSessions (~> 10.5)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/ISASwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- nanopb (< 2.30910.0, >= 2.30908.0)
- FirebaseRemoteConfig (10.7.0):
- FirebaseABTesting (~> 10.0)
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseSessions (10.10.0):
- FirebaseCore (~> 10.5)
- FirebaseCoreExtension (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.10)
- nanopb (< 2.30910.0, >= 2.30908.0)
- PromisesSwift (~> 2.1)
- GoogleAppMeasurement (10.7.0):
- GoogleAppMeasurement/AdIdSupport (= 10.7.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- GoogleUtilities/Network (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- nanopb (< 2.30910.0, >= 2.30908.0)
- GoogleAppMeasurement/AdIdSupport (10.7.0):
- GoogleAppMeasurement/WithoutAdIdSupport (= 10.7.0)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- GoogleUtilities/Network (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- nanopb (< 2.30910.0, >= 2.30908.0)
- GoogleAppMeasurement/WithoutAdIdSupport (10.7.0):
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/MethodSwizzler (~> 7.8)
- GoogleUtilities/Network (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- nanopb (< 2.30910.0, >= 2.30908.0)
- GoogleDataTransport (9.2.3):
- GoogleUtilities/Environment (~> 7.7)
- nanopb (< 2.30910.0, >= 2.30908.0)
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/AppDelegateSwizzler (7.11.1):
- GoogleUtilities/Environment
- GoogleUtilities/Logger
- GoogleUtilities/Network
- GoogleUtilities/Environment (7.11.1):
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/ISASwizzler (7.11.1)
- GoogleUtilities/Logger (7.11.1):
- GoogleUtilities/Environment
- GoogleUtilities/MethodSwizzler (7.11.1):
- GoogleUtilities/Logger
- GoogleUtilities/Network (7.11.1):
- GoogleUtilities/Logger
- "GoogleUtilities/NSData+zlib"
- GoogleUtilities/Reachability
- "GoogleUtilities/NSData+zlib (7.11.1)"
- GoogleUtilities/Reachability (7.11.1):
- GoogleUtilities/Logger
- GoogleUtilities/UserDefaults (7.11.1):
- GoogleUtilities/Logger
- nanopb (2.30909.0):
- nanopb/decode (= 2.30909.0)
- nanopb/encode (= 2.30909.0)
- nanopb/decode (2.30909.0)
- nanopb/encode (2.30909.0)
- PromisesObjC (2.2.0)
- PromisesSwift (2.2.0):
- PromisesObjC (= 2.2.0)
DEPENDENCIES:
- Alamofire
- Firebase (= 10.7.0)
- FirebaseCrashlytics (= 10.7.0)
- FirebaseDynamicLinks (= 10.7.0)
- FirebasePerformance (= 10.7.0)
- FirebaseRemoteConfig (= 10.7.0)
SPEC REPOS:
trunk:
- Alamofire
- Firebase
- FirebaseABTesting
- FirebaseAnalytics
- FirebaseCore
- FirebaseCoreExtension
- FirebaseCoreInternal
- FirebaseCrashlytics
- FirebaseDynamicLinks
- FirebaseInstallations
- FirebasePerformance
- FirebaseRemoteConfig
- FirebaseSessions
- GoogleAppMeasurement
- GoogleDataTransport
- GoogleUtilities
- nanopb
- PromisesObjC
- PromisesSwift
SPEC CHECKSUMS:
Alamofire: 4e95d97098eacb88856099c4fc79b526a299e48c
Firebase: 0219acf760880eeec8ce479895bd7767466d9f81
FirebaseABTesting: b2a87808d90f02766fcffb3957d3e397e7accc15
FirebaseAnalytics: f8133442ee6f8512e28ff19e62ce15398bfaeace
FirebaseCore: e317665b9d744727a97e623edbbed009320afdd7
FirebaseCoreExtension: 8d93ebbf6838a874b4ed82a564c9d6705f8365dd
FirebaseCoreInternal: 971029061d326000d65bfdc21f5502c75c8b0893
FirebaseCrashlytics: 35fdd1a433b31e28adcf5c8933f4c526691a1e0b
FirebaseDynamicLinks: 16a8fae3697fba66fed7a1d646fe59f30d42aa31
FirebaseInstallations: 52153982b057d3afcb4e1fbb3eb0b6d00611e681
FirebasePerformance: 8281bbaf08aad194001018b932115b7d58a6f00b
FirebaseRemoteConfig: d5de62211e2eaa2152d8ee85a23c301b70887a74
FirebaseSessions: 5f9e62cd4096e24d2011cbd845b0efceffaee1ec
GoogleAppMeasurement: fe17c92a32207dd5cdd4e8d742767f2da74857f6
GoogleDataTransport: f0308f5905a745f94fb91fea9c6cbaf3831cb1bd
GoogleUtilities: 9aa0ad5a7bc171f8bae016300bfcfa3fb8425749
nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
PromisesObjC: 09985d6d70fbe7878040aa746d78236e6946d2ef
PromisesSwift: cf9eb58666a43bbe007302226e510b16c1e10959
PODFILE CHECKSUM: be1abb165a8c7f88af2b139d4ea107cea4f424ac
COCOAPODS: 1.12.1
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 27 (16 by maintainers)
just upgraded and it did fix the issue^
@sergiocampama Thanks for isolating it to a reproducible example and testing the proposed fix! I’ll ask the team to review it this week and target it for our next release.
The problematic source code was introduced in Firebase 10.6.0 so it may work to use an earlier version.
It might be easier to stay on Xcode 15.2 instead though until the fix releases in 10.22.0.
I tested the linked PR on a locally modified copy of Firebase, and the crash does not occur any more on my repro cases 🚀
thanks for looking into it over the weekend! wish I could send you a peer bonus 😃