Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent item reload, delete, insert collisions #325

Closed
wants to merge 3 commits into from
Closed

Conversation

rnystrom
Copy link
Contributor

Changes in this pull request

Adds a new test and fixes an item animation collision that UICollectionView throws on. Basically we cannot collide reloads with insert+delete.

The example in the test is trivial, but real-world situations do appear b/c of the coalescence of IGListAdapterUpdater. It can queue reloads and deletes/inserts at the same index paths while waiting.

Pull request checklist

  • All tests pass. Demo project builds and runs.
  • I added tests, an experiment, or detailed why my change isn't tested.
  • I have reviewed the contributing guide

@rnystrom rnystrom added this to the 2.1.0 milestone Dec 13, 2016
@facebook-github-bot
Copy link
Contributor

@rnystrom updated the pull request - view changes

} else {
NSArray *indexPaths = [self indexPathsFromSectionController:sectionController indexes:indexes adjustForUpdateBlock:YES];
[self.updatingDelegate reloadItemsInCollectionView:collectionView indexPaths:indexPaths];
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😱

@jessesquires
Copy link
Contributor

Is there an open issue for this?

@jessesquires
Copy link
Contributor

update CHANGELOG 😄

@rnystrom
Copy link
Contributor Author

@jessesquires not on GH but t14617176 tracking internally, commandeered D4237742.

+1 changelog will update.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 97.952% when pulling a2fd4e9 on bad-update into 626d268 on master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 97.952% when pulling a2fd4e9 on bad-update into 626d268 on master.

@facebook-github-bot
Copy link
Contributor

@rnystrom updated the pull request - view changes

@rnystrom
Copy link
Contributor Author

rnystrom commented Dec 13, 2016

Miserable rebase, brb fixed

@facebook-github-bot
Copy link
Contributor

@rnystrom updated the pull request - view changes

@facebook-github-bot
Copy link
Contributor

@rnystrom has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 0f3e79d on bad-update into ** on master**.

2 similar comments
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 0f3e79d on bad-update into ** on master**.

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 0f3e79d on bad-update into ** on master**.

@coveralls
Copy link

coveralls commented Dec 14, 2016

Coverage Status

Coverage decreased (-0.02%) to 97.952% when pulling 0f3e79d on bad-update into 695440e on master.

@coveralls
Copy link

coveralls commented Dec 14, 2016

Coverage Status

Coverage decreased (-0.02%) to 97.952% when pulling 0f3e79d on bad-update into 695440e on master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants