dotnet / maui

.NET MAUI is the .NET Multi-platform App UI, a framework for building native device applications spanning mobile, tablet, and desktop.
https://dot.net/maui
MIT License
22.04k stars 1.73k forks source link

[Unstable][MAUI]I9_Scrolling_SnapPoints page throws System.ObjectDisposedException after setting SnapPointsType. #23528

Open ninachen03 opened 2 months ago

ninachen03 commented 2 months ago

Description

I9_Scrolling Affected case: I9_Scrolling_SnapPoints

Note: The I2 space test case sometimes throws same exception. I2-Vertical list for ItemSpacing I2-Horizontal list for ItemSpacing image

Steps to Reproduce

  1. Deploy https://devdiv.visualstudio.com/Pkgs/_git/VS.TestAssets.Xaml?path=/Assets/Projects/ManualMauiTests to Android.
  2. Navigate to 'I CollectionView' ->'I9_Scrolling ->SnapPoints page
  3. Set SnapPointsType from None to others.

Actual Behavior: I9_Scrolling_SnapPoints throw exception System.ObjectDisposedException Message=Cannot access a disposed object. Object name: 'Microsoft.Maui.Controls.Handlers.Items.MauiRecyclerView3[[Microsoft.Maui.Controls.ReorderableItemsView, Microsoft.Maui.Controls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Controls.Handlers.Items.GroupableItemsViewAdapter2[[Microsoft.Maui.Controls.ReorderableItemsView, Microsoft.Maui.Controls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Controls.Handlers.Items.IGroupableItemsViewSource, Microsoft.Maui.Controls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]], Microsoft.Maui.Controls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[Microsoft.Maui.Controls.Handlers.Items.IGroupableItemsViewSource, Microsoft.Maui.Controls, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]'. image Call stack:0x23 in ManualMauiTests.Views.VerticalListSnapPointsPage.OnSnapPointsTypeSelectedIndexChanged at C:\Users\admin\Desktop\ManualMauiTests\ManualMauiTests\Views\SnapPoints\VerticalListSnapPointsPage.xaml.cs:17,13 Expected Behavior: Can set SnapPointsType from None to others, it displays normally and does not throw any exceptions

Link to public reproduction project repository

https://devdiv.visualstudio.com/Pkgs/_git/VS.TestAssets.Xaml?path=/Assets/Projects/ManualMauiTests

Version with bug

8.0.80-ci.net8.24357.1

Is this a regression from previous behavior?

Not sure if it is a regression, because the problem is not stable and reproducible

Affected platforms

Android

Did you find any workaround?

Reopen and redeploy, it works fine since it is unstable issue.

github-actions[bot] commented 2 months ago

Hi I'm an AI powered bot that finds similar issues based off the issue title.

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it. Thank you!

Open similar issues:

Closed similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.