-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Crash when calling performUpdates with workingRangeDelegate #177
Comments
@yusuftor why are you accessing the cell in |
@rnystrom Ok I'm a bit confused then. In the WorkingRangeSectionController in the example project, it accesses the cell in And no it doesn't crash if I remove that line. What happens if you're scrolling, download a large image that takes a while in I think this is the problem that has happened to me when I have small section controllers (150px in height) with a small workingRange. I've had to increase the working range just so that |
@yusuftor the idea in that project is that if in the time since you started downloading, a cell exists, then assign the image data to that cell's image view. (your fourth paragraph is spot on) It does seem like there is a real crash/issue in here though. I'll get the sample into the config that you outlined and see what is going on. Either a Thanks for all the detail! |
@rnystrom That makes sense. That's why I've been trying to access the cell to update it, but the occasional crash issue has prevented me from doing that. No worries, if you need any extra info from me let me know! |
I just encountered this same error again. I decided to investigate and the place where it crashes is in
Specifically on the line: I tried to trace Hopefully this extra info can help you! If I find any more info I'll update this thread... |
@yusuftor -- Can you provide repro steps or a stack trace? |
@jessesquires Repro steps are the same as in my first post. The stack trace is :
|
Would it be possible to look into this bug before v2.0 is released? It seems like a fairly major bug to me as until this is fixed I can't reliably use the working range in production. No worries if not though as I know you guys are working really hard on other issues. As a side note, IGListKit has made the scrolling within my app waaay smoother than before, so thanks for that! |
@yusuftor I'm on this today, ideally I should be able to make a repro unit test and fix the crash. Very bizarre. Agree tho this should be fixed before 2.0. |
Haven't fixed it, but do have my sample project in a setup where this crash occurs. |
New issue checklist
README
and documentationGeneral information
IGListKit
version: 1.0 Master ThreadI have my workingRangeDelegate set, with a range of 2.
If you adjust the DemosViewController so that you:
demos2
where it's defined asvar demos2: [DemoItem] = []
)sectionControllerWillEnterWorkingRange
function by using the following code:It will crash with the following exception:
'NSInternalInconsistencyException', reason: 'request for number of items before section 2 when there are only 0 sections in the collection view'
I initially encountered it within my own project but found it to be reproducible using the steps above!
The text was updated successfully, but these errors were encountered: