[debugger] Add log assert to be sure that coroutineScope is not leaked

GitOrigin-RevId: 870c5f73dc01c678f3f5f75768ca8a9f18e1c610
This commit is contained in:
Maksim Zuev
2024-09-27 15:47:44 +00:00
committed by intellij-monorepo-bot
parent 8d9bcbbe47
commit 30a5861a38
@@ -247,6 +247,7 @@ class DebuggerManagerThreadImpl(parent: Disposable, private val parentScope: Cor
fun restartIfNeeded() {
if (myEvents.isClosed) {
myEvents.reopen()
LOG.assertTrue(!coroutineScope.isActive, "Coroutine scope should be cancelled")
coroutineScope = createScope()
startNewWorkerThread()
}