UITableView: Exception when Moving a Section and Reloading a Row
Originator: | adlai | ||
Number: | rdar://27041784 | Date Originated: | 06-27-2016 |
Status: | Open | Resolved: | |
Product: | iOS | Product Version: | 9.3 |
Classification: | Other Bug | Reproducible: | Always |
Area: UIKit Summary: Attempting to reload a row and move a section in the same batch update generates an exception with bad math. Steps to Reproduce: // Start with 2 sections with some rows [tableView beginUpdates] [tableView reloadRowsAtIndexPaths:@[ {1, 0} ]] [tableView moveSection:1 toSection:0] [tableView endUpdates] Expected Results: The sections switch places, and the first row in the second section reloads. Actual Results: Assertion failure: "Invalid update: invalid number of rows in section 0. The number of rows contained in an existing section after the update (3) must be equal to the number of rows contained in that section before the update (3), plus or minus the number of rows inserted or deleted from that section (0 inserted, 1 deleted) and plus or minus the number of rows moved into or out of that section (0 moved in, 0 moved out)." Version: iOS 9.3 Notes: Configuration: iPhone Simulator
Comments
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!