Xamarin forms application deployed on android showing unusual behavior and crashing

Manikanta Abburi 1 Reputation point
2022-12-14T08:21:38.737+00:00

Premise:
Around Dec1st I had reset my pc. Consequently reinstalled visual studio and resumed working on my Xamarin Forms project. Out of no where my application deployed on android device/emulator showing unusual behavior such as elements disappearing and layouts like stack layout not resizing properly and eventually crashing. This started happening after reinstallation of visual studio. Before to that everything was fine. This is something related to UI libraries or rendering I assume. Sometimes debug is giving some global object was missing thus terminating the thread kind of debug log and some times just runtime aborting.
Note : No code changes were made. from my side during this period.

Steps to Reproduce

  • Install maui option along with xamarin and intellisense in the visual studio community edition
  • Open project by clicking on project .sln file.
  • Deploy to android in debug mode.
  • Go to a page and play with it by updating a value etc.

Debug Log when crashing
270403-build-log.txt
270462-build-log-2.txt

Screen Shots
Normal Behavior
270448-screenshot-1670999603.png
270478-screenshot-1671000113.png

UI elements misbehavior as interaction happen on the UI
270496-screenshot-1671000233.png
270479-screenshot-1671000240.png

Some times just empty page is there such as when the item in the list was clicked.
270457-screenshot-1671000245.png

These mis-behaving elements are refreshed to normal, when the screen was turned off and on. (Obviously before crashing). For example list view page becomes normal on turn off and on
270480-screenshot-1671000255.png

While the above UI issues are happening, suddenly the app is crashing. Debug log to the same was uploaded above. Our app was in the production stage. Any work around or permanent solution would be good.

Developer technologies .NET Xamarin
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.