Repository navigation
ContentPage becomes slower the more times you open it and eventually ANRs #37541
Replies: 1 comment
|
Aarggh. A bad label mapping in one of our shared libraries.... |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
We're using .NET 10.0.80 on Android and have a status page with a reasonably large amount of xaml - about 56 labels, 12 images (24x24 icons with source set to MauiImages) and a couple of graphics views. Even with the view model bindings commented out so that we're just opening the page with only xaml and static resources we're finding that the more times we open the page the slower it becomes to load. The navigation is basic calls to GoToAsync("PageRoute") and GoToAsync("..");
Eventually after about 50 times it will hang and fail to open. As far as we can tell it's in whatever Maui code is processing the xaml and loading it into the page. OnAppearing has finished.
We're garbage collecting after every page close and the memory is increasing but very slowly. At start it's about 18.6MB Total Memory and by the time it hangs it's at 19.8MB Total Memory.
Even registering the Page so it's not created each time doesn't help.
Does anyone have any ideas what might be happening, how to investigate, or steps to mitigate this problem?
Update: I managed to get a stack overflow which is 1000 lines that look like the following. Any thoughts?
All reactions