MAUI Android MainPage assignments break (or crash) the app if it's backgrounded or OnResume #18921
Labels
migration-compatibility
Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert
platform/android 🤖
t/bug
Something isn't working
Description
Doing an Android MainPage assignment when the app is backgrounded or during App.xaml.cs OnResume breaks or crashes the app.
The app can either crash immediately or in some other situations the Assignment doesn't happen but it's not longer possible to do any other MainPage assignment afterwards.
Steps to Reproduce
Steps to Try:
Link to public reproduction project repository
https://github.com/dinisvieira/maui-nav-on-background/tree/main
Version with bug
8.0.3
Is this a regression from previous behavior?
Yes, this used to work in Xamarin.Forms
Last version that worked well
Unknown/Other
Affected platforms
Android
Affected platform versions
Android 11, 13 and possibly all other versions.
Did you find any workaround?
Not doing any MainPage assignments when the app is in Background or Resuming.
Relevant log output
The text was updated successfully, but these errors were encountered: