firebase / firebase-ios-sdk

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

Crash report FPRNetworkTrace.m - Line 253 #10807

Closed zamzamfp closed 1 year ago

zamzamfp commented 1 year ago

Description

I see crash reports in crashlytics with the following issues

FPRNetworkTrace.m - Line 253 -[FPRNetworkTrace didCompleteRequestWithResponse:error:] + 253

and

FPRNetworkTrace.m - Line 254 -[FPRNetworkTrace didCompleteRequestWithResponse:error:] + 254

Which belong to firebase Performance SDK.

I haven't experience these crashes running on my device working with my project but I see them in crashlytics in firebase dashboard.

I expect not to get crashes because of performance SDK.

Reproducing the issue

I have never received these crashes while working on project running on my device so I was not able to reproduce them but I see them in Crashlytics in firebase dashboard.

Firebase SDK Version

10.4.0

Xcode Version

14.0

Installation Method

Swift Package Manager

Firebase Product(s)

Analytics, App Distribution, Crashlytics, DynamicLinks, In-App Messaging, Messaging, Performance, Remote Config

Targeted Platforms

iOS

Relevant Log Output

# Crashlytics - Stack trace
# Issue: 81bde271f663058b50985626bb1cc04e
# Session: 76240df30e2c49688f6902360c409493_DNE_8_v2
# Date: Fri Feb 10 2023 16:47:01 GMT+0100 (CET)

com.apple.main-thread
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  GraphicsServices               0x1368 GSEventRunModal + 164
8  UIKitCore                      0x3a186c -[UIApplication _run] + 888
9  UIKitCore                      0x3a14d0 UIApplicationMain + 340
10 libswiftUIKit.dylib            0x35308 UIApplicationMain(_:_:_:_:) + 104
11 APP Name                       0x891c main + 4373350684 (ScoreView.swift:4373350684)
12 ???                            0x1f04be960 (Missing)

com.apple.uikit.eventfetch-thread
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  Foundation                     0x420d4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8  Foundation                     0x41fbc -[NSRunLoop(NSRunLoop) runUntilDate:] + 64
9  UIKitCore                      0x4d672c -[UIEventFetcher threadMain] + 436
10 Foundation                     0x5b5a8 __NSThread__start__ + 716
11 libsystem_pthread.dylib        0x16cc _pthread_start + 148
12 libsystem_pthread.dylib        0xba4 thread_start + 8

com.google.firebase.crashlytics.MachExceptionServer
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  APP Name                       0x39e458 FIRCLSMachExceptionServer + 192 (FIRCLSMachException.c:192)
5  libsystem_pthread.dylib        0x16cc _pthread_start + 148
6  libsystem_pthread.dylib        0xba4 thread_start + 8

Thread
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  Instabug                       0x3759d8 exception_server_thread + 188
5  libsystem_pthread.dylib        0x16cc _pthread_start + 148
6  libsystem_pthread.dylib        0xba4 thread_start + 8

Thread
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  APP Name                       0x523604 exception_server_thread + 7596
5  libsystem_pthread.dylib        0x16cc _pthread_start + 148
6  libsystem_pthread.dylib        0xba4 thread_start + 8

com.apple.NSURLConnectionLoader
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  CFNetwork                      0x258078 _CFURLStorageSessionDisableCache + 61088
8  Foundation                     0x5b5a8 __NSThread__start__ + 716
9  libsystem_pthread.dylib        0x16cc _pthread_start + 148
10 libsystem_pthread.dylib        0xba4 thread_start + 8

Thread
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  Foundation                     0x420d4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8  APP Name                       0x48e89c -[GCKBackgroundThread main] + 15 (GCKBackgroundThread.m:15)
9  Foundation                     0x5b5a8 __NSThread__start__ + 716
10 libsystem_pthread.dylib        0x16cc _pthread_start + 148
11 libsystem_pthread.dylib        0xba4 thread_start + 8

com.apple.CFSocket.private
0  libsystem_kernel.dylib         0x560c __select + 8
1  libsystem_kernel.dylib         0x560c select$DARWIN_EXTSN + 8
2  CoreFoundation                 0xcb6a4 __CFSocketManager + 636
3  libsystem_pthread.dylib        0x16cc _pthread_start + 148
4  libsystem_pthread.dylib        0xba4 thread_start + 8

com.apple.CFNetwork.CustomProtocols
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  CFNetwork                      0x258078 _CFURLStorageSessionDisableCache + 61088
8  Foundation                     0x5b5a8 __NSThread__start__ + 716
9  libsystem_pthread.dylib        0x16cc _pthread_start + 148
10 libsystem_pthread.dylib        0xba4 thread_start + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

Crashed: IBGURLSessionDemux (QOS: UNSPECIFIED)
0  libobjc.A.dylib                0x3554 objc_release_x0 + 16
1  libobjc.A.dylib                0x3554 objc_release + 16
2  APP Name                       0x3423d0 -[FPRNetworkTrace didCompleteRequestWithResponse:error:] + 254 (FPRNetworkTrace.m:254)
3  APP Name                       0x345d4c __InstrumentURLSessionTaskDidCompleteWithError_block_invoke + 54 (FPRNSURLSessionDelegateInstrument.m:54)
4  CFNetwork                      0x1a554 CFURLRequestCopyHTTPRequestMethod + 2272
5  Foundation                     0xa70f0 __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 24
6  Foundation                     0x7b240 -[NSBlockOperation main] + 104
7  Foundation                     0x7b1d0 __NSOPERATION_IS_INVOKING_MAIN__ + 16
8  Foundation                     0x3c578 -[NSOperation start] + 708
9  Foundation                     0x3c2ac __NSOPERATIONQUEUE_IS_STARTING_AN_OPERATION__ + 16
10 Foundation                     0x419c0 __NSOQSchedule_f + 172
11 libdispatch.dylib              0x13114 _dispatch_block_async_invoke2 + 148
12 libdispatch.dylib              0x3fdc _dispatch_client_callout + 20
13 libdispatch.dylib              0x746c _dispatch_continuation_pop + 504
14 libdispatch.dylib              0x6ad4 _dispatch_async_redirect_invoke + 584
15 libdispatch.dylib              0x15a6c _dispatch_root_queue_drain + 396
16 libdispatch.dylib              0x16284 _dispatch_worker_thread2 + 164
17 libsystem_pthread.dylib        0xdbc _pthread_wqthread + 228
18 libsystem_pthread.dylib        0xb98 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0x4fb0 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0xe44 _pthread_wqthread + 364
2  libsystem_pthread.dylib        0xb98 start_wqthread + 8

com.apple.SwiftUI.AsyncRenderer
0  libsystem_kernel.dylib         0x4aa8 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x16fc4 mach_msg2_internal + 80
2  libsystem_kernel.dylib         0x17204 mach_msg_overwrite + 388
3  libsystem_kernel.dylib         0x4fec mach_msg + 24
4  CoreFoundation                 0x7aad4 __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x7bd18 __CFRunLoopRun + 1232
6  CoreFoundation                 0x80ec0 CFRunLoopRunSpecific + 612
7  Foundation                     0x420d4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8  Foundation                     0x41f68 -[NSRunLoop(NSRunLoop) run] + 64
9  SwiftUI                        0xa757c OUTLINED_FUNCTION_581 + 864
10 SwiftUI                        0xa56dc __swift_memcpy40_8 + 2160
11 Foundation                     0x5b5a8 __NSThread__start__ + 716
12 libsystem_pthread.dylib        0x16cc _pthread_start + 148
13 libsystem_pthread.dylib        0xba4 thread_start + 8

com.apple.coremedia.rootQueue.47
0  libsystem_kernel.dylib         0x4a3c semaphore_timedwait_trap + 8
1  libdispatch.dylib              0x45f4 _dispatch_sema4_timedwait + 64
2  libdispatch.dylib              0x4bf4 _dispatch_semaphore_wait_slow + 76
3  libdispatch.dylib              0x15840 _dispatch_worker_thread + 324
4  libsystem_pthread.dylib        0x16cc _pthread_start + 148
5  libsystem_pthread.dylib        0xba4 thread_start + 8

com.apple.coremedia.rootQueue.47
0  libsystem_kernel.dylib         0x4a3c semaphore_timedwait_trap + 8
1  libdispatch.dylib              0x45f4 _dispatch_sema4_timedwait + 64
2  libdispatch.dylib              0x4bf4 _dispatch_semaphore_wait_slow + 76
3  libdispatch.dylib              0x15840 _dispatch_worker_thread + 324
4  libsystem_pthread.dylib        0x16cc _pthread_start + 148
5  libsystem_pthread.dylib        0xba4 thread_start + 8

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

Expand Package.resolved snippet
```json { "identity" : "firebase-ios-sdk", "kind" : "remoteSourceControl", "location" : "https://github.com/firebase/firebase-ios-sdk", "state" : { "revision" : "0df86ea17d5d281415be74f2290df8431644f156", "version" : "10.4.0" } } ```

If using CocoaPods, the project's Podfile.lock

Expand Podfile.lock snippet
```yml Replace this line with the contents of your Podfile.lock! ```
google-oss-bot commented 1 year ago

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

rizafran commented 1 year ago

Thanks for reporting, @zamzamfp. May I know if the crash is causing some strange behavior in Performance SDK?

zamzamfp commented 1 year ago

Hi @rizafran, no not really, everything looks okay on performance dashboard. I just removed the Performance SDK in my latest release to see if the crashes will stop showing up. I would really like to use the performance SDK, but If it keeps causing crashes I can't keep it in the project. If there is anything specific you want from me to help you look into it let me know.

morganchen12 commented 1 year ago

@zamzamfp if you run your app with NSZombies enabled, are you able to get this to repro?

google-oss-bot commented 1 year ago

Hey @zamzamfp. 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!

google-oss-bot commented 1 year ago

Since there haven't been any recent updates here, I am going to close this issue.

@zamzamfp if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.