Scenario 1: When ListView is not grouped, then selecting an item and try to group the ListView and collapsing the groups, then exception occurs.
Scenario 2: When ListView is grouped, then selecting an item and ungroup, the item is still selected, then group with collapseall and exception:
The issue occurs on iOS version > 16.