Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[iOS] Cannot access a disposed object using CollectionView EmptyView #12923

Merged
merged 6 commits into from
Dec 11, 2020

Conversation

jsuarezruiz
Copy link
Contributor

@jsuarezruiz jsuarezruiz commented Nov 20, 2020

Description of Change

Cannot access a disposed object exception using CollectionView EmptyView.

I cannot reproduce the issue neither in the repro sample created, nor using the 5.0.0 branch with the example attached in #12776 (see attached gif). Using Xamarin.Forms 5.0-pre4 can reproduce the issue.@hartez has submitted a few CollectionView fixes recently, but I cannot associate a direct change related to EmptyView that may have fixed the issue. For now, I created this PR as a draft to investigate more.

Issues Resolved

API Changes

None

Platforms Affected

  • iOS

Behavioral/Visual Changes

None

Before/After Screenshots

fix12910

Testing Procedure

Launch Core Gallery and navigate to the issue 12910. Pull to Refresh. Without exceptions, the test has passed.

PR Checklist

  • Targets the correct branch
  • Tests are passing (or failures are unrelated)

@jsuarezruiz jsuarezruiz added t/bug 🐛 p/iOS 🍎 i/high Completely doesn't work, crashes, or is unusably slow, has no obvious workaround; occurs less often a/collectionview labels Nov 20, 2020
@VladislavAntonyuk
Copy link
Contributor

Thank you @jsuarezruiz for the hot fix. Do you have a Nuget package I can take to check?
XCT has awesome bot for it:
image

@jsuarezruiz jsuarezruiz marked this pull request as ready for review November 24, 2020 10:56
@Mertsch
Copy link

Mertsch commented Dec 6, 2020

For me this issue happens both directly and indirectly.
Directly: Enter view, boom exception
Indirectly: View is displayed correctly. Trying to navigate from view (page) to a different (without CV) then exception.
No idea why, but the issue is gone as soon as I comment EmptyView

@rmarinho rmarinho merged commit 15fc853 into 5.0.0 Dec 11, 2020
@rmarinho rmarinho deleted the fix-12910 branch December 11, 2020 11:54
@samhouts samhouts modified the milestone: 5.0.0 Dec 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a/carouselview a/collectionview i/high Completely doesn't work, crashes, or is unusably slow, has no obvious workaround; occurs less often p/iOS 🍎 t/bug 🐛
Projects
None yet
6 participants