You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NSRangeException: *** -[NSMutableIndexSet addIndexesInRange:]: Range {18446744073709551614, 1} exceeds maximum index value of NSNotFound - 1
File "WPPHAssetDataSource.m", line 375, in -[WPPHAssetDataSource adjustedIndexesForIndexSet:forCount:]
File "WPPHAssetDataSource.m", line 369, in -[WPPHAssetDataSource adjustedIndexesForIndexSet:]
File "WPPHAssetDataSource.m", line 101, in __45-[WPPHAssetDataSource photoLibraryDidChange:]_block_invoke
File "main.swift", line 7, in main
...
(15 additional frame(s) were not displayed)
The text was updated successfully, but these errors were encountered:
I tried removing/adding photos while the device media picker is open, but couldn't get it to crash. I also tested a scenario when the device is empty.
Message:
NSRangeException: *** -[NSMutableIndexSet addIndexesInRange:]: Range {18446744073709551534, 1} exceeds maximum index value of NSNotFound - 1`
The likely explanation is that there is something wrong with this method or the way it is called:
- (NSInteger)adjustedIndexForIndex:(NSInteger)index forCount:(NSInteger)count
{
if (self.ascendingOrdering) {
return index;
}
// Adjust the index so items are returned in reverse order.
// We do this, rather than specifying the sort order in PHFetchOptions,
// to preserve the sort order of assets in the Photos app (only in reverse).
return (count - 1) - index;
}
The value 18446744073709551534 may be the result of converting a negative value, such as -1, from NSInteger to NSUInteger that NSIndexSet works with.
I'm assigning a low priority because it happens extremely rarely.
The best solution would be to replace the custom picker with a native picker that supports search, filtering by favorites, and many other features.
Sentry Issue: JETPACK-IOS-G84
The text was updated successfully, but these errors were encountered: