Xamarin.forms: [Bug] NSInternalInconsistencyException thrown in grouped CollectionView on iOS 10

Created on 2 Jan 2020  路  12Comments  路  Source: xamarin/Xamarin.Forms

Description

An NSInternalInconsistencyException is thrown with a grouped CollectionView on iOS 10.
This may possibly be related to #7393.

Steps to Reproduce

  1. Open the attached sample project on an IOS 10 device.
  2. The app will crash.

Expected Behavior

The app does no crash on iOS 11 and above.
_Note: Behavior is untested on iOS9._

Actual Behavior

The app crashes with the following exception:

Foundation.MonoTouchException: 'Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: layout attributes for supplementary item at index path (<NSIndexPath: 0x167248f0> {length = 2, path = 0 - 0}) changed from <UICollectionViewLayoutAttributes: 0x17825740> index path: (<NSIndexPath: 0x17825660> {length = 2, path = 0 - 0}); element kind: (UICollectionElementKindSectionHeader); frame = (0 0; 0 0); to <UICollectionViewLayoutAttributes: 0x16724870> index path: (<NSIndexPath: 0x167248f0> {length = 2, path = 0 - 0}); element kind: (UICollectionElementKindSectionHeader); frame = (0 0; 720 19.5); zIndex = 10; without invalidating the layout

Basic Information

  • Version with issue: 4.4.0
  • Last known good version: N/A
  • IDE: Microsoft Visual Studio 2019 Enterprise
  • Platform Target Frameworks:

    • iOS: 13.6.0.12

  • Affected Devices: iPad iOS 10.3.3

Reproduction Link

CollectionViewCrashIOS10.zip

collectionview high iOS 馃崕 tablet bug

Most helpful comment

Hi @hartez, I was just wondering if the XF team had any update on this? We're not really in a position to drop support for our iOS 10 users yet. Are there any plans to work on this any time soon? Thanks!

All 12 comments

Trying to keep our iOS 10 clients alive... Thanks!

Any update on this?

@hartez @samhouts We鈥檙e currently blocked due to this bug, as grouped collection views are broken for iOS 10 users. Do you possibly have an ETA for this fix?

@samhouts @hartez I can confirm this is still broken in the latest master and 4.4.0/4.5.0 branches. I tested on the iOS 10.3 simulator and the same crash occurred.

Hi @hartez, I was just wondering if the XF team had any update on this? We're not really in a position to drop support for our iOS 10 users yet. Are there any plans to work on this any time soon? Thanks!

Hi @samhouts. Just following up on this issue - If the XF team do not plan to resolve this issue, is iOS 10 effectively unsupported by XF going forward? Just keen to understand the direction of the team on this one as we still have a considerable iOS 10 user base. Thanks!

We're not planning to drop support for iOS10 just yet.

This is on the backlog. I don't currently have an estimate of when we may begin work on this item, but it is high priority. Thank you for your patience!

@samhouts Thank you very much. Great to see some of the other iOS 10 issues getting traction in the current sprint. We're eagerly awaiting this fix!

This is fixed in 4.7 pre4.

Fantastic, thanks @hartez - we can confirm this is fixed in our codebase upgrading to 4.7 pre4.
Great work!

Still happening on the latest stable release 4.7.0.1179

@libin85 Can you please open a new issue? Thanks!

Was this page helpful?
0 / 5 - 0 ratings