unoplatform / uno

Open-source platform for building cross-platform native Mobile, Web, Desktop and Embedded apps quickly. Create rich, C#/XAML, single-codebase apps from any IDE. Hot Reload included! 90m+ NuGet Downloads!!
https://platform.uno
Apache License 2.0
8.88k stars 717 forks source link

DataGrid binding in macOS not working for asynchronously fetched data #6375

Closed AmitEMV closed 4 months ago

AmitEMV commented 3 years ago

Current behavior

DataGrid's ItemSource is bound to a List from the ViewModel. This List is populated during load asynchronously and in this scenario, it hangs\crashes on macOS. The DataGrid is in a DataTemplate which is used in a ContentPresenter finally.

Expected behavior

List will bind successfully and the app will display the bound data.

How to reproduce it (as minimally and precisely as possible)

Simple repo to reproduce the issue. Running the app reproduces the issue as there is nothing else in the code - delay is simulated for the asynchronous action and data is bound after that.

Works on UWP/WinUI

It works in UWP, Android and Linux (SKia.Gtk) as well. Here is another repo targeting these platforms for the same behaviour.

Environment

Nuget Package Version(s):
Uno.UI v3.8.6. Prerelease for Uno.Microsoft.Xaml.Behaviors.Uwp.Managed v2.0.3-uno.95

Affected platform(s):

IDE:

Relevant plugins:

AmitEMV commented 3 years ago

I removed other project heads before checking it into Git, so they're absent in the macOS repo.

AmitEMV commented 3 years ago

@jeromelaban Is there any workaround that you would recommend that I can use for now?

MartinZikmund commented 4 months ago

This is no longer relevant as we have a new macOS backend 🚀