-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Intermittent crash in FUtilities.intForString #9096
Comments
I found a few problems with this issue:
|
Thanks for reporting, @softwaresaiyajin. Could you try updating your SDK to the latest version and see if you'll still encounter the issue? If so, could you share an MCVE reproducing the issue? |
Will try that |
The crash might be related to some particular data in the database. Are you able to catch the crash in the debugger and explore what is triggering the crash. As mentioned above, a reproducible example would be helpful for diagnosis. |
Crash still happening in 8.10.0. I cannot provide a reproducible example as it's happening intermittently. Seems to be the same as this one: firebase/quickstart-unity#809. |
To elaborate a bit more @paulb777 the crash is only happening for app version which is using SPM implementation, old version which is using cocoapods works fine so it seems that it is probably not the data that is invalid. Afaik when I experienced this crash string was Here is example firebase log: Crashed: com.apple.main-thread
0 libobjc.A.dylib 0x2474 objc_msgSend + 20
1 CoreFoundation 0x542d4 CFCharacterSetInitInlineBuffer + 60
2 CoreFoundation 0xc9ca0 CFStringFindCharacterFromSet + 184
3 Foundation 0x2b7d8 -[NSString rangeOfCharacterFromSet:options:range:] + 204
4 AppName 0x147385c +[FUtilities intForString:] + 302 (FUtilities.m:302)
5 AppName 0x14696b4 __30-[FChildrenNode valForExport:]_block_invoke + 190 (FChildrenNode.m:190)
6 AppName 0x1477c48 -[FArraySortedDictionary enumerateKeysAndObjectsReverse:usingBlock:] + 233 (FArraySortedDictionary.m:233)
7 AppName 0x146a5b0 -[FChildrenNode enumerateChildrenUsingBlock:] + 367 (FChildrenNode.m:367)
8 AppName 0x1469310 -[FChildrenNode valForExport:] + 202 (FChildrenNode.m:202)
9 AppName 0x14695e8 __30-[FChildrenNode valForExport:]_block_invoke + 176 (FChildrenNode.m:176)
10 AppName 0x1477c48 -[FArraySortedDictionary enumerateKeysAndObjectsReverse:usingBlock:] + 233 (FArraySortedDictionary.m:233)
11 AppName 0x146a5b0 -[FChildrenNode enumerateChildrenUsingBlock:] + 367 (FChildrenNode.m:367)
12 AppName 0x1469310 -[FChildrenNode valForExport:] + 202 (FChildrenNode.m:202)
13 AppName 0x14695e8 __30-[FChildrenNode valForExport:]_block_invoke + 176 (FChildrenNode.m:176)
14 AppName 0x1477c48 -[FArraySortedDictionary enumerateKeysAndObjectsReverse:usingBlock:] + 233 (FArraySortedDictionary.m:233)
15 AppName 0x146a5b0 -[FChildrenNode enumerateChildrenUsingBlock:] + 367 (FChildrenNode.m:367)
16 AppName 0x1469310 -[FChildrenNode valForExport:] + 202 (FChildrenNode.m:202)
17 AppName 0x14695e8 __30-[FChildrenNode valForExport:]_block_invoke + 176 (FChildrenNode.m:176)
18 AppName 0x1477c48 -[FArraySortedDictionary enumerateKeysAndObjectsReverse:usingBlock:] + 233 (FArraySortedDictionary.m:233)
19 AppName 0x146a5b0 -[FChildrenNode enumerateChildrenUsingBlock:] + 367 (FChildrenNode.m:367)
20 AppName 0x1469310 -[FChildrenNode valForExport:] + 202 (FChildrenNode.m:202)
21 AppName 0x14695e8 __30-[FChildrenNode valForExport:]_block_invoke + 176 (FChildrenNode.m:176)
22 AppName 0x1477c48 -[FArraySortedDictionary enumerateKeysAndObjectsReverse:usingBlock:] + 233 (FArraySortedDictionary.m:233)
23 AppName 0x146a5b0 -[FChildrenNode enumerateChildrenUsingBlock:] + 367 (FChildrenNode.m:367)
24 AppName 0x1469310 -[FChildrenNode valForExport:] + 202 (FChildrenNode.m:202)
25 AppName 0x1418418 -[FIRDataSnapshot value] + 40 (FIRDataSnapshot.m:40)
26 AppName 0x13fbff8 closure #1 in closure #1 in FirebaseAPIClient.get(query:) + 38 (FirebaseAPIClient.swift:38)
27 AppName 0x1404930 thunk for @escaping @callee_guaranteed (@guaranteed FIRDataSnapshot) -> () + 3999952 (<compiler-generated>:3999952)
28 AppName 0x141e35c __92-[FIRDatabaseQuery observeSingleEventOfType:andPreviousSiblingKeyWithBlock:withCancelBlock:]_block_invoke + 740 (FIRDatabaseQuery.m:740)
29 AppName 0x1449e08 __43-[FChildEventRegistration fireEvent:queue:]_block_invoke.62 + 90 (FChildEventRegistration.m:90)
30 libdispatch.dylib 0x60298 _dispatch_call_block_and_release + 24
31 libdispatch.dylib 0x61280 _dispatch_client_callout + 16
32 libdispatch.dylib 0x435b0 _dispatch_main_queue_callback_4CF$VARIANT$armv81 + 856
33 CoreFoundation 0x9a5e0 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12
34 CoreFoundation 0x94a88 __CFRunLoopRun + 2480
35 CoreFoundation 0x93ba0 CFRunLoopRunSpecific + 572
36 GraphicsServices 0x3598 GSEventRunModal + 160
37 UIKitCore 0xb2e2f4 -[UIApplication _run] + 1052
38 UIKitCore 0xb33874 UIApplicationMain + 164 |
Thanks - there's a race condition in that code that could cause this crash. I'll make a PR .... |
Thank you @paulb777 ! Do you know approximately when can we expect |
@Pattio 8.11.0 is planned for January. In the meantime, you could manually apply the fix to your installation. |
[REQUIRED] Step 1: Describe your environment
Swift Package Manager
iOS
[REQUIRED] Step 2: Describe the problem
FUtilities.intForString
Steps to reproduce:
What happened? How can we make the problem occur?
This could be a description, log/console output, etc.
If you have a downloadable sample project that reproduces the bug you're reporting, you will
likely receive a faster response on your issue.
Relevant Code:
crashlog.txt
The text was updated successfully, but these errors were encountered: