07/24/2022, 11:01 AM
Is it safe to use Coroutines runBlocking() inside onDataSetChanged of RemoteViewsFactory? I am trying to fetch some latest movie images and display it in the Android app widgets, As per the requirement the widget should refresh every hour to get the latest movies images. Since I am using coroutines throughout the app, I need to use the existing retrofit services with suspend function to get the data. As per the Android documentation, its safe to do heavy operation inside onDataSetChanged of RemoteViewsFactory So I am using this method itself to fetch data from service instead of...