I suspect the key is in this line from the article:
This indicates a checked exception was somehow being synchronously thrown.
the immediate dispatcher always runs synchronously if possible, without a suspend boundary, so you can have the exception thrown in the proxy quite easily
p
Paul Woitaschek
11/07/2019, 9:53 AM
I hope this can be fixed. Just refactoring everything back to singles now for my release -.-
l
louiscad
11/07/2019, 11:28 AM
I'd just use
Dispatchers.Main
when dealing with retrofiit to avoid that issue. I'm wondering if you could have the issue when using
Dispatchers.Default
or
<http://Dispatchers.IO|Dispatchers.IO>
too 🤔
p
Paul Woitaschek
11/07/2019, 11:30 AM
In my case it's the viewmodel which collects from a flow on the immediate dispatcher as default because else there are artifacts when one source of the viewstate flow is a user input event.
To my viewmodel it's not transparent that there is room somewhere in the chain, it originates somewhere in a repository