Hello, I am having a tableview with multiple sections (more than 10), which can be expanded and collapsed to show about 13 rows. The expanding part works ok, but when I am near the end of the tableView and I want to collapse an expanded sections, the tableView scrolls up leaving a gap (it has a negative content offset - ex. -320), and goes to normal when you start interacting with the tableView. I couldn't figure it out why the table view has this weird behavior. The rows deletion code is done inside performBatchUpdates.
Do you have any ideas what could cause this issue?
NOTE: The behavior seems to be correct on iOS 10. Seems to be broken from iOS 11.