Open saurabhkumar8112 opened 4 months ago
Thank you for the suggestion and for highlighting the common issue . Yes offloading this to a separate thread with a timeout mechanism is a thoughtful approach to enhance the robustness of the application. i will try this otherwise if u open a PL if you can
Its a common problem that accessibility service often leads to ANRs because of timeouts in onListen/locks(
ANR triggered by main thread waiting for too long
).Do you think it would be better to offload the processing inside onListen to a separate thread with a timeout? If the Thread doesn't finish processing within a set time, timeout it and exit the onListen.
What does the author think?
Something like this