https://kotlinlang.org logo
#coroutines
Title
# coroutines
f

Fudge

08/05/2022, 6:55 AM
I have some coroutine code that is getting cancelled with a
JobCancellationException
. How can I pinpoint the exact line of code that actually caused the coroutine to cancel? I've tried setting an exception breakpoint for
JobCancellationException
, but it doesn't get triggered for some reason.
m

myanmarking

08/05/2022, 8:29 AM
paste the code
u

uli

08/05/2022, 11:38 PM
You can try and set a break point in the constructor of the exception
Or in Job.cancel()
f

Fudge

08/06/2022, 2:22 PM
I can't paste the code, we're talking about many files, and the cancellation occurs in library code even
@uli I'll try that, thanks
g

gildor

08/06/2022, 3:25 PM
Have you tried to enable coroutines debug mode?
f

Fudge

08/12/2022, 2:31 PM
No, I will try that as well
2 Views