Version 0.3.0 and version 0.2.0 bug
HackShitUp opened this issue · 11 comments
I use AnimatedCollectionViewLayout a bit differently by storing UITableViews and UITableViewCells in them with the parent UIViewController referenced with a protocol. In other words, it's architected like so:
UITableViewCell --> UITableView --> UICollectionViewCell --> UICollectionView --> UIViewController (using AnimatedCollectionViewLayout)
The parent class using this framework may or may not return a UICollectionViewCell with a UITableView init, and all the UITableViewDataSource and Delegate methods are managed in the parent class (we used our own protocol to do this). BUT, when I updated to version 0.3.0, the frames are frozen when the transition occurs. The animator used is the
ParallaxAttributesAnimator
I think the error occurs because of one of the return values in the animations. Please take a look when you can, and if you need help feel free to reach out!
Hey, is it possible for you to share a simple example that demonstrates this issue?
@KelvinJin thanks for your swift response. How do you mean by demo? Do you want the source files? I can send them to you privately if you'd like!
It would be helpful to have a minimum version of the project that can reproduce the bug. Will make it easier for me to diagnose the issue too. And yeah, it's fine to send me privately.
@KelvinJin Alright, I'll share a private repo with you soon
@KelvinJin Hey, I just realized that the scope of what I made is a bit large and may be difficult to comprehend. BUT I did create a repo with 2 source files with a READ.ME that explains how the project is architected. If you need to contact me, my email is josh.m.choi@gmail.com. Also, I think it might help if you try out the app in the App Store (https://redplanetapp.com/)...
Hey, thanks for sharing the code. I'm looking at both the app and the code but since I can't run the project (due to some missing files), I'm not sure why this bug happens.
Can you confirm that this bug only happens in v0.3.0? Can you try specify 0.2.0 in the Podfile and see if the bug exists?
Do the current version of the RedPlanet app use this library to do those transitions? Is that 0.2.0 or some earlier versions?
Hi @KelvinJin sorry for the late response. Yes, I can confirm that the current version of Redplanet (v3.4.91) on the App Store uses AnimatedCollectionViewLayout version 0.2.0. I actually updated Cocoapods ACVL to 0.3.0, found the bug in ACVL and then ended up downgrading back to 0.2.0 before releasing the current version. Last time I checked, I think it might've been a return value in one of the animation transition functions. I'll take a look at it tonight and keep you posted to see if I can replicate the bug again more thoroughly.
@KelvinJin I just found the bug. It occurs when you scroll/swipe from:
(A) a UICollectionViewCell with a UITableView and UITableViewCell to (B) a regular UICollectionViewCell, XIB.
If you don't mind taking a look at it, I'll send you the full source code without access keys. Let me know if that'll be alright for you because I currently can't figure out how my code is causing the UICollectionView scroll to freeze.
Hey, thanks for letting me know. Is it occurring only on iOS 11? AFAIK, version 0.3.0 only changed a tiny bit thing that shouldn't make much difference from 0.2.0.
I'm sorry but it will be really hard for me to locate the bug in a full project. Hope you can understand. If you can abstract the faulty view out (with mock data) and make sure I can run it and reproduce the bug, it would be much easier for me...
@KelvinJin actually, I don't think it has anything to do with iOS 11. And yes! I'm working on that. I'll be creating a mockup/replica with fixed data so you can take a look at it! I'll share the repo with you ASAP as soon as I complete it!