firebase / firebase-ios-sdk

Firebase SDK for Apple App Development
https://firebase.google.com
Apache License 2.0
5.51k stars 1.44k forks source link

pb_check_proto3_default_value EXC_BAD_ACCESS (KERN_INVALID_ADDRESS) #12632

Closed AhmedShanab74 closed 4 months ago

AhmedShanab74 commented 5 months ago

Description

Released app version 2.0.12 on 3/26 using Xcode 15.3, Encountered a critical crash issue on the same day , reported via Firebase

Environments: Xcode version: Xcode 15.3 macOS version: macOS Sonoma 14.3.1 Firebase version: Firebase(10.20.0)

Reproducing the issue

i have update firebase to version 10.20.0 and upload app to app store , when user try to update the app from app store app crash
i also update firebase to 10.22.0 and have the same issue

img_1 img_2

Firebase SDK Version

10.20.0 and i update to 10.22.0

Xcode Version

15.3

Installation Method

CocoaPods

Firebase Product(s)

All

Targeted Platforms

iOS

Relevant Log Output

Crashed: com.apple.main-thread
0  nanopb                         0x6904 pb_check_proto3_default_value + 342
1  nanopb                         0x6074 pb_encode + 172
2  FirebaseSessions               0x413c FIRSESEncodeProto + 64
3  FirebaseSessions               0xf04c $s16FirebaseSessions17SessionStartEventC14transportBytes10Foundation4DataVyF + 232
4  FirebaseSessions               0xf2d4 $s16FirebaseSessions17SessionStartEventC14transportBytes10Foundation4DataVyFTo + 28
5  GoogleDataTransport            0xdfac -[GDTCOREvent setDataObject:] + 68
6  GoogleDataTransport            0xde3c -[GDTCOREvent copy] + 72
7  GoogleDataTransport            0x1b000 -[GDTCORTransport sendEvent:onComplete:] + 44
8  FirebaseSessions               0xa834 $sSo15GDTCORTransportC16FirebaseSessions27GoogleDataTransportProtocolA2cDP11logGDTEvent5event10completionySo11GDTCOREventC_ys6ResultOyyts5Error_pGctFTW + 176
9  FirebaseSessions               0x5ec0 $s16FirebaseSessions14EventGDTLoggerC03logC05event10completionyAA012SessionStartC0C_ys6ResultOyyts5Error_pGctF + 224
10 FirebaseSessions               0x5f44 $s16FirebaseSessions14EventGDTLoggerCAA0cD8ProtocolA2aDP03logC05event10completionyAA012SessionStartC0C_ys6ResultOyyts5Error_pGctFTW + 20
11 FirebaseSessions               0xd1c4 $s16FirebaseSessions18SessionCoordinatorC014attemptLoggingC5Start5event8callbackyAA0cG5EventC_ys6ResultOyytAA0aB5ErrorOGctFyAMcfU_ + 176
12 FirebaseSessions               0xd3c4 $s16FirebaseSessions18SessionCoordinatorC10fillInFIID33_A99E81F187A7BA47A5374F4DC053A423LL5event8callbackyAA0C10StartEventC_ys6ResultOyytAA0aB5ErrorOGctFyAKySSs0V0_pGcfU_ + 180
13 FirebaseSessions               0xabe4 $sSo16FIRInstallationsC16FirebaseSessionsE14installationID10completionyys6ResultOySSs5Error_pGc_tFySSSg_sAH_pSgtcfU_TA + 48
14 FirebaseSessions               0xaaa8 $sSSSgs5Error_pSgIeggg_So8NSStringCSgSo7NSErrorCSgIeyByy_TR + 96
15 FirebaseInstallations          0x49bc __49-[FIRInstallations installationIDWithCompletion:]_block_invoke + 56
16 FBLPromises                    0x5130 __56-[FBLPromise chainOnQueue:chainedFulfill:chainedReject:]_block_invoke.18 + 52
17 libdispatch.dylib              0x26a8 <redacted> + 32
18 libdispatch.dylib              0x4300 <redacted> + 20
19 libdispatch.dylib              0x129e0 <redacted> + 1056
20 libdispatch.dylib              0x125b0 _dispatch_main_queue_callback_4CF + 44
21 CoreFoundation                 0x36f9c <redacted> + 16
22 CoreFoundation                 0x33ca8 <redacted> + 1996
23 CoreFoundation                 0x333f8 CFRunLoopRunSpecific + 608
24 GraphicsServices               0x34f8 GSEventRunModal + 164
25 UIKitCore                      0x22c8a0 <redacted> + 888
26 UIKitCore                      0x22bedc UIApplicationMain + 340
27 MyApp                       0x10a910 main + 39 (AppDelegate.swift:39)
28 ???                            0x1b5cfadcc (Missing)

If using Swift Package Manager, the project's Package.resolved

Expand Package.resolved snippet
```json Replace this line with the contents of your Package.resolved. ```

If using CocoaPods, the project's Podfile.lock

PODS:

DEPENDENCIES:

SPEC REPOS: trunk:

SPEC CHECKSUMS: Adjust: c98d85594a746ff9f2bafe424c5beb6db66cd6a8 Alamofire: 02b772c9910e8eba1a079227c32fbd9e46c90a24 AlamofireEasyLogger: f2fd10b57d973593a79a4b61f274c6a5cb3e1333 AlgoliaSearchClient: dd74cf9fc8c9ccb4145b77b435945068dcd4ce50 AlignedCollectionViewFlowLayout: ee2ef451e741ec08f8e0967d828001e2f051c20a BadgeHub: b227771329f78c37a2dae7502607ec6d00a50bd4 BEMCheckBox: 5ba6e37ade3d3657b36caecc35c8b75c6c2b1a4e Cosmos: b5c6a9a637e28a061b54c8f8b1d8529d7d4db73f CountryPickerView: 6322ada32a80b0cd721b0267282a5c24f406f263 DropDown: 8a2116376c1981888557f72ec2ffc9a5e0e456ec DynamicBlurView: 58e18fae80bb614e34681a4486870e7d257b62e8 Firebase: 797fd7297b7e1be954432743a0b3f90038e45a71 FirebaseABTesting: aec61ed9a34d85a95e2013a3fdf051426a2419df FirebaseCore: 0326ec9b05fbed8f8716cddbf0e36894a13837f7 FirebaseCoreExtension: cb88851781a24e031d1b58e0bd01eb1f46b044b5 FirebaseCoreInternal: 6a292e6f0bece1243a737e81556e56e5e19282e3 FirebaseCrashlytics: e568d68ce89117c80cddb04073ab9018725fbb8c FirebaseInAppMessaging: bff8ac490bba54c298b48847e14bd56313d2da1b FirebaseInstallations: 42d6ead4605d6eafb3b6683674e80e18eb6f2c35 FirebaseMessaging: 9f71037fd9db3376a4caa54e5a3949d1027b4b6e FirebaseRemoteConfig: e1b992a94d3674dddbcaf5d0d31a0312156ceb1c FirebaseSessions: f06853e30f99fe42aa511014d7ee6c8c319f08a3 FirebaseSharedSwift: c92645b392db3c41a83a0aa967de16f8bad25568 FittedSheets: 7f754c9f6fb4ea330cbc57c652b594255f2a6819 FSPagerView: 670405b2f18e2a87fa37f20b00de783e562c25a8 GoogleDataTransport: 6c09b596d841063d76d4288cc2d2f42cc36e1e2a GoogleUtilities: d053d902a8edaa9904e1bd00c37535385b8ed152 ImageSlideshow: be305b54eaf2b2cfc7a7141c7c734605d44dc07d InstantSearch: dfa1e71207059951d40aefc8e981bcf6199a5c27 InstantSearchTelemetry: e1ea763a63ad2db96b4f5e8bc4cd4cc1147274b9 IQKeyboardManagerSwift: d338c11a896e9f29603443700c4567e32f830c22 Kingfisher: 6c5449c6450c5239166510ba04afe374a98afc4f LinearProgressBar: 619d6f286b608e501f39406557f60cdab3faf910 Logging: beeb016c9c80cf77042d62e83495816847ef108b lottie-ios: 8f97d3271e155c2d688875c29cd3c74908aef5f8 MOLH: e45827d200aeb1310641090fd8cd03ad2b42ae72 nanopb: 438bc412db1928dac798aa6fd75726007be04262 NVActivityIndicatorView: ec7440a57af2450319d3a4181cca7da6fc127064 OneSignal: 67a3cf1d1edf2a9c22ba846e8d2eee2bf8cdb525 OneSignalXCFramework: 3c3ef25ecca5eae1bf80a3272c49fd1dbab96b35 PayPalCheckout: 9ecb796c36f899426bb2e10aec08cd236b5f022e PopupDialog: 720c92befd8bc23c13442254945213db5612f149 Presentr: 7078d7eb5d1661ebeaae60c9e42a1e534de1b993 PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47 PromisesSwift: 9d77319bbe72ebf6d872900551f7eeba9bce2851 RSKPlaceholderTextView: 85cb165bfbfe160a2e7bfb6bcd77a21100ce1b52 RxCocoa: 44a80de90e25b739b5aeaae3c8c371a32e3343cc RxRelay: 45eaa5db8ee4fb50e5ebd57deec0159e97fa51e6 RxSwift: a4b44f7d24599f674deebd1818eab82e58410632 SkyFloatingLabelTextField: 79ddc40e4ad59707fedbb48d605417aee48bb78a SMLocalize: 8e64c09714627d5537225bff8be464e965230859 SwiftLuhn: 20ec3fe2b00699f5b2867c0133236722b05b902d SwiftMessages: f0c7ef4705a570ad6c5e208b611f4333e660ed92 SwiftProtobuf: 407a385e97fd206c4fbe880cc84123989167e0d1 SwiftyUserDefaults: 6a1951df1daa19337862b677dd9a4b9bd4c288cd Toast-Swift: dd369e68ee529f542c65bd0d0c6c50cd743cf6f2

PODFILE CHECKSUM: 48d1d769c18cf6740ff4839cf358d79525a20c7e

COCOAPODS: 1.12.1

google-oss-bot commented 5 months ago

I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.

paulb777 commented 5 months ago

Please confirm that you're reproducing with 10.22.0 or 10.23.0.

This is exactly the bug (#11403) that was fixed for several others with those releases.

AhmedShanab74 commented 5 months ago

hello @paulb777 i update Firebase to 10.23.0 and still have the same crash the crash happened when i start downloading the app My Podfile.lock

https://github.com/firebase/firebase-ios-sdk/assets/128382748/0dd27c26-b55f-4c21-ad60-af8b5e291d28

paulb777 commented 5 months ago

Are you able to reproduce locally building in Xcode? Does it make a difference to build for Debug or to build for Release?

AhmedShanab74 commented 5 months ago

when i run the version 2.0.12 from xcode it works fine without crashes

paulb777 commented 5 months ago

OK, we'll need a crash in a reproducible example built with Firebase 10.23.0 to make progress here.

AhmedShanab74 commented 4 months ago

hi @paulb777
users have an old version of the app 2.0.11 when they open the app an popup appears tell them they need to force update the app , the version on app store is 2.0.12 when they download it the app crash these screen shots are from Crashlytics dashboard of the app here the url of the app on store ==>> https://apps.apple.com/eg/app/marasi-shopping-%D9%85%D8%B1%D8%A7%D8%B3%D9%8A-%D9%84%D9%84%D8%AA%D8%B3%D9%88%D9%82/id1476963784?l=ar

img-1 img-2 img-3
AhmedShanab74 commented 4 months ago

@paulb777 notice that all crashes happened in ios 17

fee-dev commented 4 months ago

I encountered the same issue where I'm unable to publish my app live because it crashes on the device when I'm testing and downloading a new version from TestFlight.

AhmedShanab74 commented 4 months ago

@fee-dev Did the same problem occur with Firebase 10.23.0 ?

ram-vilash commented 4 months ago

After updating the firebase version it is still crashing in iOS 17

guperini commented 4 months ago

Same issue here. The app crashes in the first session after update.

google-oss-bot commented 4 months ago

Hey @AhmedShanab74. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

aarcoraci commented 4 months ago

Some users have also reported this error to me recently.

Relevant log output:

Crashed: com.apple.main-thread
0  nanopb                         0x6904 pb_check_proto3_default_value + 342
1  nanopb                         0x6074 pb_encode + 172
2  FirebaseSessions               0x413c FIRSESEncodeProto + 64
3  FirebaseSessions               0xef10 $s16FirebaseSessions17SessionStartEventC14transportBytes10Foundation4DataVyF + 232
4  FirebaseSessions               0xf198 $s16FirebaseSessions17SessionStartEventC14transportBytes10Foundation4DataVyFTo + 28
5  GoogleDataTransport            0xde9c -[GDTCOREvent setDataObject:] + 68
6  FirebaseSessions               0x5e84 $s16FirebaseSessions14EventGDTLoggerC03logC05event10completionyAA012SessionStartC0C_ys6ResultOyyts5Error_pGctF + 104
7  FirebaseSessions               0x5f80 $s16FirebaseSessions14EventGDTLoggerCAA0cD8ProtocolA2aDP03logC05event10completionyAA012SessionStartC0C_ys6ResultOyyts5Error_pGctFTW + 20
8  FirebaseSessions               0xd0c8 $s16FirebaseSessions18SessionCoordinatorC014attemptLoggingC5Start5event8callbackyAA0cG5EventC_ys6ResultOyytAA0aB5ErrorOGctFyAMcfU_ + 176
9  FirebaseSessions               0xd2c8 $s16FirebaseSessions18SessionCoordinatorC10fillInFIID33_A99E81F187A7BA47A5374F4DC053A423LL5event8callbackyAA0C10StartEventC_ys6ResultOyytAA0aB5ErrorOGctFyAKySSs0V0_pGcfU_ + 180
10 FirebaseSessions               0xaafc $sSo16FIRInstallationsC16FirebaseSessionsE14installationID10completionyys6ResultOySSs5Error_pGc_tFySSSg_sAH_pSgtcfU_TA + 48
11 FirebaseSessions               0xa9c0 $sSSSgs5Error_pSgIeggg_So8NSStringCSgSo7NSErrorCSgIeyByy_TR + 96
12 FirebaseInstallations          0x49c0 __49-[FIRInstallations installationIDWithCompletion:]_block_invoke + 56
13 FBLPromises                    0x5138 __56-[FBLPromise chainOnQueue:chainedFulfill:chainedReject:]_block_invoke.18 + 52
14 libdispatch.dylib              0x26a8 <redacted> + 32
15 libdispatch.dylib              0x4300 <redacted> + 20
16 libdispatch.dylib              0x129e0 <redacted> + 1056
17 libdispatch.dylib              0x125b0 _dispatch_main_queue_callback_4CF + 44
18 CoreFoundation                 0x36f9c <redacted> + 16
19 CoreFoundation                 0x33ca8 <redacted> + 1996
20 CoreFoundation                 0x333f8 CFRunLoopRunSpecific + 608
21 GraphicsServices               0x34f8 GSEventRunModal + 164
22 UIKitCore                      0x22c8a0 <redacted> + 888
23 UIKitCore                      0x22bedc UIApplicationMain + 340
24 Runner                         0xf60c main + 6 (AppDelegate.swift:6)
25 ???                            0x1bc3c2dcc (Missing)
paulb777 commented 4 months ago

I'm going to close and lock this issue.

This bug (https://github.com/firebase/firebase-ios-sdk/issues/11403) was fixed in Firebase 10.22.0. If you have this problem in a newer version, please open a new issue with the template fully completed.