PerformBatchUpdates crashes with NSInternalInconsistencyException requesting absurd index

Originator:smiller
Number:rdar://32544063 Date Originated:June 2 2017, 2:09 PM
Status:Closed Resolved:
Product:iOS + SDK Product Version:All iPhone and iOS versions
Classification:UIKit Reproducible:Unable
 
Area:
UIKit

Summary:
Please see the included stack traces for this bug.

We are unable to reproduce this crash, but it has started occurring in as high as 0.1% of sessions. While we do not have reproduction steps, we know that when using `UICollectionView.reloadSections` instead of `UICollectionView.reloadData` this crash does not occur. 

Because `UICollectionView.reloadSections` instead of `UICollectionView.reloadData` fixes the crashes we suspect that this is similar to the bug filed in Bug Report #32543861 (https://openradar.appspot.com/32543861).

Steps to Reproduce:
Unknown. We have been unsuccessful in attempts to reproduce this bug.

It seems that a similar crash has been reported in bug report #27354858 (https://openradar.appspot.com/27354858) which has reproduction steps. However, we do not use `insertItems` in the `performBatchUpdates` or elsewhere in our code. We do use `insertSections` but only once at the beginning of our `UICollectionView` lifecycle.

Steps to Reproduce:
Unknown. We have been unsuccessful in attempts to reproduce this bug.

It seems that a similar crash has been reported in bug report #27354858, https://openradar.appspot.com/27354858 which has reproduction steps. However, we do not use `insertItems` in the `performBatchUpdates` or elsewhere in our code. We do use `insertSections` but only once at the beginning of our `UICollectionView` lifecycle.

Expected Results:
No crashes.

Observed Results:
Crashes.

Version:
All iOS versions, it seems there is a reduced number of crashes on iOS 10.3, but it is unclear.

Notes:


Configuration:
All iPhone devices, there seems to be no correlation to hardware.

Comments

Apple Developer Relations [October 12 2017, 2:02 PM]

No response from the originator, now closing the bug report.

Apple Developer Relations [September 19 2017, 11:39 AM]

Please verify this issue with the iOS 11 GM and update your bug report at https://bugreport.apple.com/ with your results.

iOS 11 GM (15A372) https://developer.apple.com/download/ Posted Date: Sep 19th, 2017

If the issue persists, please attach a new sysdiagnose captured in the latest build and attach it to the bug report. Thank you.

iOS sysdiagnose Instructions: https://developer.apple.com/services-account/download?path=/iOS/iOS_Logs/sysdiagnose_Logging_Instructions.pdf


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!