[regression/8.0.0-rc1] [Android] Removing ItemSource item in ListView causes crash #17028
Labels
area-controls-listview
ListView and TableView
fixed-in-8.0.0-rc.1.9171
Look for this fix in 8.0.0-rc.1.9171
high
It doesn't work at all, crashes or has a big impact.
i/regression
This issue described a confirmed regression on a currently supported version
platform/android 🤖
t/bug
Something isn't working
Milestone
Description
If you have a dynamic ItemSource on a ListView, and remove any item other than the last item in the given source, your application will crash on an error
The specified child already has a parent. You must call removeView() on the child's parent first.
.Steps to Reproduce
Checkout my repro project and run it against MAUI Main.
In the current (7.0.92, .NET 8 Preview) builds it should work, but in Main it should fail.
Link to public reproduction project repository
https://github.com/drasticactions/MauiRepros/tree/main/ListViewMaui7
Version with bug
Unknown/Other
Is this a regression from previous behavior?
Yes, this used to work in .NET MAUI
Last version that worked well
7.0.92
Affected platforms
Android
Affected platform versions
Android
Did you find any workaround?
Don't remove the first item in an ItemSource on a listview.
Relevant log output
The text was updated successfully, but these errors were encountered: