Skip to content
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

[iOS] NRE after calling ViewCell.ForceUpdateSize #23092

Closed
VitalyKnyazev opened this issue Jun 17, 2024 · 1 comment
Closed

[iOS] NRE after calling ViewCell.ForceUpdateSize #23092

VitalyKnyazev opened this issue Jun 17, 2024 · 1 comment
Labels
area-controls-listview ListView and TableView fixed-in-8.0.61 i/regression This issue described a confirmed regression on a currently supported version migration-compatibility Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert p/0 Work that we can't release without platform/iOS 🍎 t/bug Something isn't working
Milestone

Comments

@VitalyKnyazev
Copy link
Contributor

Description

A ListView with HasUnevenRows set to true causes NRE when view cell calls ForceUpdateSize to resize itself on iOS.
It seems to be caused by #22067 fix.

Steps to Reproduce

Launch sample project in iPhone simulator and click "Toggle description visibility" button.

Link to public reproduction project repository

https://github.com/VitalyKnyazev/MauiViewCellCrash

Version with bug

8.0.60 SR6

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI, Yes, this used to work in Xamarin.Forms

Last version that worked well

8.0.40 SR5

Affected platforms

iOS

Affected platform versions

iOS 17

Did you find any workaround?

No

Relevant log output

Object reference not set to an instance of an object.

   at Microsoft.Maui.Controls.Cell.OnForceUpdateSizeRequested()
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
   at Foundation.NSAsyncSynchronizationContextDispatcher.Apply() in /Users/builder/azdo/_work/1/s/xamarin-macios/src/Foundation/NSAction.cs:line 176
--- End of stack trace from previous location ---
   at ObjCRuntime.Runtime.ThrowException(IntPtr gchandle) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/ObjCRuntime/Runtime.cs:line 2594
   at UIKit.UIApplication.UIApplicationMain(Int32 argc, String[] argv, IntPtr principalClassName, IntPtr delegateClassName) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:line 60
   at UIKit.UIApplication.Main(String[] args, Type principalClass, Type delegateClass) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:line 94
   at MoneyTracker.Universal.Maui.Program.Main(String[] args) in E:\Projects\Git\Working\MoneyTrackerPro\MoneyTracker.Universal.Maui\Platforms\iOS\Program.cs:line 12
@VitalyKnyazev VitalyKnyazev added the t/bug Something isn't working label Jun 17, 2024
Copy link
Contributor

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.

VitalyKnyazev added a commit to VitalyKnyazev/maui that referenced this issue Jun 17, 2024
@PureWeen PureWeen added this to the .NET 8 SR6 milestone Jun 17, 2024
@samhouts samhouts added potential-regression This issue described a possible regression on a currently supported version., verification pending migration-compatibiity labels Jun 17, 2024
@PureWeen PureWeen added the p/0 Work that we can't release without label Jun 17, 2024
@samhouts samhouts added migration-compatibility Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert and removed migration-compatibiity labels Jun 17, 2024
@samhouts samhouts added fixed-in-8.0.61 i/regression This issue described a confirmed regression on a currently supported version and removed potential-regression This issue described a possible regression on a currently supported version., verification pending labels Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-controls-listview ListView and TableView fixed-in-8.0.61 i/regression This issue described a confirmed regression on a currently supported version migration-compatibility Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert p/0 Work that we can't release without platform/iOS 🍎 t/bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants