firebase-ios-sdk
firebase-ios-sdk copied to clipboard
Crash - GDTCORWriteDataToFile
Description
We are experiencing a crash on GDTCORPlatform.m line 295
(GDTCORWriteDataToFile
).
Here is the stack trace:
Crashed: com.google.GDTCORFlatFileStorage
0 CoreFoundation 0x77f30 CFDictionaryGetValue + 72
1 CoreFoundation 0x176f94 _CFBundleGetStringsSources + 1968
2 CoreFoundation 0x6edb4 CFBundleGetLocalInfoDictionary + 192
3 CoreFoundation 0x59260 CFBundleGetValueForInfoDictionaryKey + 40
4 Foundation 0x58ee0 -[NSFileManager _URLForReplacingItemAtURL:error:] + 628
5 Foundation 0x58a04 _NSCreateTemporaryFile_Protected + 164
6 Foundation 0x66a0c _NSWriteDataToFileWithExtendedAttributes + 432
7 App 0x1c4a2c GDTCORWriteDataToFile + 295 (GDTCORPlatform.m:295)
8 App 0x1bd7fc __47-[GDTCORFlatFileStorage storeEvent:onComplete:]_block_invoke.42 + 171 (GDTCORFlatFileStorage.m:171)
9 libdispatch.dylib 0x63850 _dispatch_call_block_and_release + 24
10 libdispatch.dylib 0x647c8 _dispatch_client_callout + 16
11 libdispatch.dylib 0x3f854 _dispatch_lane_serial_drain$VARIANT$armv81 + 604
12 libdispatch.dylib 0x402e4 _dispatch_lane_invoke$VARIANT$armv81 + 380
13 libdispatch.dylib 0x4a000 _dispatch_workloop_worker_thread + 612
14 libsystem_pthread.dylib 0x1b50 _pthread_wqthread + 284
15 libsystem_pthread.dylib 0x167c start_wqthread + 8
Reproducing the issue
No response
Firebase SDK Version
10.0.0
Xcode Version
14.1
Installation Method
Swift Package Manager
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
{
"pins" : [
{
"identity" : "abseil-cpp-swiftpm",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/abseil-cpp-SwiftPM.git",
"state" : {
"revision" : "583de9bd60f66b40e78d08599cc92036c2e7e4e1",
"version" : "0.20220203.2"
}
},
{
"identity" : "boringssl-swiftpm",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/boringssl-SwiftPM.git",
"state" : {
"revision" : "dd3eda2b05a3f459fc3073695ad1b28659066eab",
"version" : "0.9.1"
}
},
{
"identity" : "firebase-ios-sdk",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/firebase-ios-sdk.git",
"state" : {
"revision" : "5c4893c55f9d6114e2bb7c691d7ffd81208ac713",
"version" : "10.0.0"
}
},
{
"identity" : "leveldb",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/leveldb.git",
"state" : {
"revision" : "0706abcc6b0bd9cedfbb015ba840e4a780b5159b",
"version" : "1.22.2"
}
},
{
"identity" : "nanopb",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/nanopb.git",
"state" : {
"revision" : "819d0a2173aff699fb8c364b6fb906f7cdb1a692",
"version" : "2.30909.0"
}
}
],
"version" : 2
}
If using CocoaPods, the project's Podfile.lock
Expand Podfile.lock
snippet
Replace this line with the contents of your Podfile.lock!
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
Thanks for reporting, @mustafauskuplu. Is the issue reproducible locally? If so, could you provide the detailed steps in reproducing the issue?
Hello @rizafran . Thanks for looking into the issue.
Unfortunately, this is not something I can reproduce locally.
Here is the stack trace for multiple threads. Maybe it will help 🤷♂️
Crashed: com.google.GDTCORFlatFileStorage
0 CoreFoundation 0x7cbf4 CFDictionaryGetValue + 92
1 CoreFoundation 0x18ca3c _CFBundleGetStringsSources + 1976
2 CoreFoundation 0x73698 CFBundleGetLocalInfoDictionary + 196
3 CoreFoundation 0x5d374 CFBundleGetValueForInfoDictionaryKey + 44
4 Foundation 0x5eae8 -[NSFileManager _URLForReplacingItemAtURL:error:] + 648
5 Foundation 0x5e5f8 _NSCreateTemporaryFile_Protected + 168
6 Foundation 0x6d184 _NSWriteDataToFileWithExtendedAttributes + 436
7 App 0x1c4a2c GDTCORWriteDataToFile + 295 (GDTCORPlatform.m:295)
8 App 0x1bd7fc __47-[GDTCORFlatFileStorage storeEvent:onComplete:]_block_invoke.42 + 171 (GDTCORFlatFileStorage.m:171)
9 libdispatch.dylib 0x24b4 _dispatch_call_block_and_release + 32
10 libdispatch.dylib 0x3fdc _dispatch_client_callout + 20
11 libdispatch.dylib 0xb694 _dispatch_lane_serial_drain + 672
12 libdispatch.dylib 0xc1e0 _dispatch_lane_invoke + 384
13 libdispatch.dylib 0x16e10 _dispatch_workloop_worker_thread + 652
14 libsystem_pthread.dylib 0xdf8 _pthread_wqthread + 288
15 libsystem_pthread.dylib 0xb98 start_wqthread + 8
---------------------------------------------------------------------------------------------------------------------------------
com.apple.main-thread
0 libsystem_kernel.dylib 0xb48 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x13008 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x13248 mach_msg_overwrite + 388
3 libsystem_kernel.dylib 0x108c mach_msg + 24
4 libdispatch.dylib 0x1f364 _dispatch_mach_send_and_wait_for_reply + 540
5 libdispatch.dylib 0x1f6ec dispatch_mach_send_with_result_and_wait_for_reply + 60
6 libxpc.dylib 0x102e4 xpc_connection_send_message_with_reply_sync + 240
7 Foundation 0xa3344 __NSXPCCONNECTION_IS_WAITING_FOR_A_SYNCHRONOUS_REPLY__ + 16
8 Foundation 0x3646c -[NSXPCConnection _sendInvocation:orArguments:count:methodSignature:selector:withProxy:] + 2236
9 CoreFoundation 0x1fd60 ___forwarding___ + 1016
10 CoreFoundation 0x88350 _CF_forwarding_prep_0 + 96
11 CacheDelete 0x17f0c __CacheDeleteCopyAvailableSpaceForVolume_block_invoke + 164
12 CacheDelete 0xac40 CallBlockWithProxy + 636
13 CacheDelete 0x258c CacheDeleteCopyAvailableSpaceForVolume + 1252
14 CoreServicesInternal 0x97bc volumePropertyProviderPrepareValues(__CFURL const*, __FileCache*, __CFString const* const*, void const**, long, void const*, __CFError**) + 2216
15 CoreServicesInternal 0x6c9c prepareValuesForBitmap(__CFURL const*, __FileCache*, _FilePropertyBitmap*, __CFError**) + 452
16 CoreServicesInternal 0x38c4 _FSURLCopyResourcePropertiesForKeysInternal(__CFURL const*, __CFArray const*, void*, __CFError**, unsigned char) + 1288
17 CoreFoundation 0xc3dc4 CFURLCopyResourcePropertiesForKeys + 100
18 CoreFoundation 0x39500 -[NSURL resourceValuesForKeys:error:] + 96
19 Foundation 0x257cc0 URL.resourceValues(forKeys:) + 140
20 Foundation 0x257ad4 URL.resourceValues(forKeys:) + 24
21 EnsightenSwift 0x4769c block_destroy_helper + 472
22 EnsightenSwift 0x46a98 _swift_stdlib_malloc_size + 9268
23 EnsightenSwift 0x4738c _swift_stdlib_malloc_size + 11560
24 EnsightenSwift 0x47c78 block_destroy_helper + 1972
25 EnsightenSwift 0x446c4 _swift_stdlib_malloc_size + 96
26 libdispatch.dylib 0x24b4 _dispatch_call_block_and_release + 32
27 libdispatch.dylib 0x3fdc _dispatch_client_callout + 20
28 libdispatch.dylib 0x127f4 _dispatch_main_queue_drain + 928
29 libdispatch.dylib 0x12444 _dispatch_main_queue_callback_4CF + 44
30 CoreFoundation 0x9a6f8 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
31 CoreFoundation 0x7c058 __CFRunLoopRun + 2036
32 CoreFoundation 0x80ed4 CFRunLoopRunSpecific + 612
33 GraphicsServices 0x1368 GSEventRunModal + 164
34 UIKitCore 0x3a23d0 -[UIApplication _run] + 888
35 UIKitCore 0x3a2034 UIApplicationMain + 340
36 App 0x7fcc main + 30 (AppDelegate.swift:30)
37 ??? 0x1c9f34960 (Missing)
---------------------------------------------------------------------------------------------------------------------------------
com.apple.uikit.eventfetch-thread
0 libsystem_kernel.dylib 0xb48 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x13008 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x13248 mach_msg_overwrite + 388
3 libsystem_kernel.dylib 0x108c mach_msg + 24
4 CoreFoundation 0x7aaf0 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x7bd34 __CFRunLoopRun + 1232
6 CoreFoundation 0x80ed4 CFRunLoopRunSpecific + 612
7 Foundation 0x42334 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8 Foundation 0x4221c -[NSRunLoop(NSRunLoop) runUntilDate:] + 64
9 UIKitCore 0x4d733c -[UIEventFetcher threadMain] + 436
10 Foundation 0x5b808 __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 App 0xe5517c FIRCLSProcessRecordAllThreads + 393 (FIRCLSProcess.c:393)
1 App 0xe5555c FIRCLSProcessRecordAllThreads + 424 (FIRCLSProcess.c:424)
2 App 0xe62a08 FIRCLSHandler + 34 (FIRCLSHandler.m:34)
3 App 0xe63204 FIRCLSMachExceptionServer + 521 (FIRCLSMachException.c:521)
4 libsystem_pthread.dylib 0x16cc _pthread_start + 148
5 libsystem_pthread.dylib 0xba4 thread_start + 8
---------------------------------------------------------------------------------------------------------------------------------
JavaScriptCore libpas scavenger
0 libsystem_kernel.dylib 0x141c __psynch_cvwait + 8
1 libsystem_pthread.dylib 0x806c _pthread_cond_wait + 1232
2 JavaScriptCore 0xf6324 scavenger_thread_main + 1164
3 libsystem_pthread.dylib 0x16cc _pthread_start + 148
4 libsystem_pthread.dylib 0xba4 thread_start + 8
---------------------------------------------------------------------------------------------------------------------------------
com.apple.NSURLConnectionLoader
0 libsystem_kernel.dylib 0xb48 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x13008 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x13248 mach_msg_overwrite + 388
3 libsystem_kernel.dylib 0x108c mach_msg + 24
4 CoreFoundation 0x7aaf0 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x7bd34 __CFRunLoopRun + 1232
6 CoreFoundation 0x80ed4 CFRunLoopRunSpecific + 612
7 CFNetwork 0x2565a8 _CFURLStorageSessionDisableCache + 61088
8 Foundation 0x5b808 __NSThread__start__ + 716
9 libsystem_pthread.dylib 0x16cc _pthread_start + 148
10 libsystem_pthread.dylib 0xba4 thread_start + 8
---------------------------------------------------------------------------------------------------------------------------------
UserComponent
0 libsystem_kernel.dylib 0xac4 semaphore_wait_trap + 8
1 libdispatch.dylib 0x4578 _dispatch_sema4_wait + 28
2 libdispatch.dylib 0x4c2c _dispatch_semaphore_wait_slow + 132
3 libswiftDispatch.dylib 0x195c OS_dispatch_semaphore.wait(wallTimeout:) + 24
4 App 0x8a1a44 Response.wait(seconds:) + 290 (Response.swift:290)
5 App 0x2d138 closure #1 in UserComponent.pollUserAccount(_:) + 4343517496 (<compiler-generated>:4343517496)
6 App 0x88b024 partial apply for closure #1 in Component<>.asyncIfNeeded(block:) + 4352290852 (<compiler-generated>:4352290852)
7 App 0x887be8 thunk for @escaping @callee_guaranteed () -> () + 4352277480 (<compiler-generated>:4352277480)
8 libdispatch.dylib 0x24b4 _dispatch_call_block_and_release + 32
9 libdispatch.dylib 0x3fdc _dispatch_client_callout + 20
10 libdispatch.dylib 0xb694 _dispatch_lane_serial_drain + 672
11 libdispatch.dylib 0xc1e0 _dispatch_lane_invoke + 384
12 libdispatch.dylib 0x16e10 _dispatch_workloop_worker_thread + 652
13 libsystem_pthread.dylib 0xdf8 _pthread_wqthread + 288
14 libsystem_pthread.dylib 0xb98 start_wqthread + 8
I've got the same issue randomly (but rarely), on probably an event for a store event on a view shown event. (can not share logs)
Hi @kvacquier, are you also using the Performance SDK?
Yes I am, thats probably the reason.
Since the Performance SDK seems to be the common denominator here, I too am thinking this may be related to an issue like https://github.com/firebase/firebase-ios-sdk/issues/6734 (or one of the linked issues at the bottom of that one).
@visumickey, could you PTAL?
Any updates on this? I'm experiencing the same issue:
Crashed: com.google.GDTCORFlatFileStorage
0 CoreFoundation 0x7cbc8 CFDictionaryGetValue + 92
1 CoreFoundation 0x18ca0c _CFBundleGetStringsSources + 1976
2 CoreFoundation 0x73648 CFBundleGetLocalInfoDictionary + 196
3 CoreFoundation 0x5d324 CFBundleGetValueForInfoDictionaryKey + 44
4 Foundation 0x5e7f8 -[NSFileManager _URLForReplacingItemAtURL:error:] + 648
5 Foundation 0x5e308 _NSCreateTemporaryFile_Protected + 168
6 Foundation 0x6ce94 _NSWriteDataToFileWithExtendedAttributes + 436
7 PPGames 0x15ce30 GDTCORWriteDataToFile + 4337454640
8 PPGames 0x156988 __47-[GDTCORFlatFileStorage storeEvent:onComplete:]_block_invoke.60 + 4337428872
9 libdispatch.dylib 0x2460 _dispatch_call_block_and_release + 32
10 libdispatch.dylib 0x3f88 _dispatch_client_callout + 20
11 libdispatch.dylib 0xb640 _dispatch_lane_serial_drain + 672
12 libdispatch.dylib 0xc18c _dispatch_lane_invoke + 384
13 libdispatch.dylib 0x16e10 _dispatch_workloop_worker_thread + 652
14 libsystem_pthread.dylib 0xdf8 _pthread_wqthread + 288
15 libsystem_pthread.dylib 0xb98 start_wqthread + 8
These are the Firebase dependencies and versions that we are using:
binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseAnalyticsBinary.json" "8.15.0"
binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseCrashlyticsBinary.json" "8.15.0"
binary "https://dl.google.com/dl/firebase/ios/carthage/FirebasePerformanceBinary.json" "8.15.0"
![image](https://user-images.githubusercontent.com/130378284/235068909-cd707358-8164-41e7-bd26-6377fec7779d.png)
I cannot reproduce the issue locally.
Do you know what can be the cause of this crash or some advices to prevent this from happening?
Hey guys, any update on this issue? I'm experiencing the same problem here and I really needed a solution.
def googleRepository pod 'Firebase', '10.5.0' pod 'FirebaseAnalytics', '10.5.0' pod 'FirebaseCrashlytics', '10.5.0' pod 'FirebaseCore', '10.5.0' pod 'FirebasePerformance', '10.5.0' pod 'FirebaseDynamicLinks', '10.5.0' pod 'GoogleAnalytics', '3.21.0' pod 'GoogleAppMeasurement', '10.5.0' pod 'GoogleConversionTracking', '3.4.0' pod 'GoogleSymbolUtilities', '1.1.2' pod 'GoogleTagManager', '7.4.3' pod 'GoogleUtilities', '7.8.0' pod 'GoogleToolboxForMac', '2.3.1' pod 'GoogleUtilitiesLegacy', '1.3.2'
end
We haven't yet been able to reproduce and diagnose. Does removing the FirebasePerformance pod resolve the crash?
We haven't yet been able to reproduce and diagnose. Does removing the FirebasePerformance pod resolve the crash?
It is not possible remove this lib as it is being used in my project
Can you try disabling instrumentation instead of removing Performance from your app entirely?
Hey @mustafauskuplu. 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!
Since there haven't been any recent updates here, I am going to close this issue.
@mustafauskuplu 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.