Skip to content

Track ANRs #2174

Answered by mattjohnsonpint
hot33331 asked this question in Q&A
Discussion options

You must be logged in to vote

Not in Xamarin Forms, but we already do this for MAUI. Presently it's on by default for Android only. To turn it on for iOS, add this to your UseSentry options:

#if __IOS__
		options.iOS.EnableAppHangTracking = true;
#endif

We'll be setting it on by default when we address issue #2148.

Also note that while these will track and report ANRs, the reported stack trace will be in native code - not necessarily the C# code that generated the hang. We would have some work to do to light that up. I created an issue for that - #2179.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by mattjohnsonpint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants