Hi, I'm having the same issue. Did you find a solution ?
Post
Replies
Boosts
Views
Activity
Hi
I think we're having the same issue, did you find a solution ?
Our app is crashing (100% repro) on an iPhone 11 with iOS 14.0.0 (18A373). Alas I can't debug directly the app on this iPhone.
The crash happens when using a SwiftUI binding to go back in a NavigationView from a screen containing a picker. My guess is that picker is kept around for the duration of the animation but it's data is destroyed leading to a out of range when refreshing it's datasource.
Note that this trace doesn't contain any line of our code, the crash happens in SwiftUI / UIKit.
side note: the website refuse that I upload my trace as a txt file as you suggested to I'll paste it here.
Crashed: com.apple.main-thread
0	libswiftCore.dylib						 0x1ae6035b8 closure #1 in closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 384
1	libswiftCore.dylib						 0x1ae602ac4 _assertionFailure(_:_:file:line:flags:) + 472
2	libswiftCore.dylib						 0x1ae5e0e94 _ArrayBuffer._checkInoutAndNativeTypeCheckedBounds(_:wasNativeTypeChecked:) + 212
3	libswiftCore.dylib						 0x1ae5e74d8 Array.subscript.read + 160
4	libswiftCore.dylib						 0x1ae5e740c protocol witness for Collection.subscript.read in conformance [A] + 68
5	SwiftUI												0x1b180f1e8 CoreCoordinator.pickerView(_:viewForRow:forComponent:reusing:) + 884
6	SwiftUI												0x1b180f3a4 @objc CoreCoordinator.pickerView(_:viewForRow:forComponent:reusing:) + 100
7	UIKitCore											0x1ad3861f8 -[UIPickerView tableView:cellForRowAtIndexPath:] + 560
8	UIKitCore											0x1ad37c584 -[UIPickerColumnView tableView:cellForRowAtIndexPath:] + 168
9	UIKitCore											0x1ad619580 -[UITableView _createPreparedCellForGlobalRow:withIndexPath:willDisplay:] + 644
10 UIKitCore											0x1ad5e5eac -[UITableView _updateVisibleCellsNow:] + 2476
11 UIKitCore											0x1ad603a90 -[UITableView layoutSubviews] + 356
12 UIKitCore											0x1ad37f52c __35-[UIPickerTableView layoutSubviews]_block_invoke + 92
13 UIKitCore											0x1ad918a60 +[UIView(Animation) performWithoutAnimation:] + 104
14 UIKitCore											0x1ad37f4c4 -[UIPickerTableView layoutSubviews] + 116
15 UIKitCore											0x1ad925dd4 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 2500
16 QuartzCore										 0x1ade2f280 -[CALayer layoutSublayers] + 296
17 QuartzCore										 0x1ade2f73c CA::Layer::layout_if_needed(CA::Transaction*) + 524
18 QuartzCore										 0x1ade43b64 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 144
19 QuartzCore										 0x1add8b114 CA::Context::commit_transaction(CA::Transaction*, double, double*) + 416
20 QuartzCore										 0x1addb6418 CA::Transaction::commit() + 732
21 QuartzCore										 0x1addb7778 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) + 96
22 CoreFoundation								 0x1aaa5a444 CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION + 36
23 CoreFoundation								 0x1aaa54858 __CFRunLoopDoObservers + 576
24 CoreFoundation								 0x1aaa54e08 __CFRunLoopRun + 1056
25 CoreFoundation								 0x1aaa544bc CFRunLoopRunSpecific + 600
26 GraphicsServices							 0x1c14d9820 GSEventRunModal + 164
27 UIKitCore											0x1ad3f8734 -[UIApplication _run] + 1072
28 UIKitCore											0x1ad3fde10 UIApplicationMain + 168
29 Applicant.testing							0x104e326a8 main + 20 (AppCoordinator.swift:20)
30 libdyld.dylib									0x1aa71be60 start + 4