Use the bgCoroutineContext to update note shortcut
- Application scope is using Dispatchers.Main.immediate causing ANRs when updating note-taking shortcuts. So using bgCoroutineContext when when updating note-tasks. - Internally bgCoroutineContext uses Dispatchers.IO which should help avoid the ANR in SysUI. - Using the new CoroutineScope.launch function that supports tracing to help debug future potential ANRs. Bug: 311325103 Test: atest NoteTaskControllerTest Flag: NA Change-Id: I179d49285c7184200e11754fc0c735c55d1ed0d0
Loading
Please register or sign in to comment