Open User-Admin opened 4 months ago
Do you have a code sample on what you're doing when you switch rooms?
fun roomDisConnected(tokenData: String?) { mutablePrimarySpeaker.value = null room.localParticipant.cleanup() room.disconnect()
lifecycleScope.launch {
delay(500)
connectToRoom(tokenData)
}
}
There is a 500-millisecond delay in entering the room, otherwise another problem will arise:
😄Are there any new solutions to this problem now ?
Doing a couple internal fixes that will also likely address this.
I don't understand what you mean. Do I need to check the code and fix it internally? In the later version iteration, the room initialization exception will be handled synchronously?
Just that the upcoming version has some fixes that may prevent this bug from happening. Haven't had time to check this specific bug.
hi,Is there any new progress on this issue? I use the latest 2.4.0 SDK here, but this problem still occurs
Describe the bug kotlin.UninitializedPropertyAccessException: subscriber has not been initialized yet. at io.livekit.android.room.RTCEngine.getSubscriber$livekit_android_sdk_release(RTCEngine.kt:128) at io.livekit.android.room.RTCEngine.onTrickle(RTCEngine.kt:733) at io.livekit.android.room.SignalClient.handleSignalResponseImpl(SignalClient.kt:586) at io.livekit.android.room.SignalClient.access$handleSignalResponseImpl(SignalClient.kt:56) at io.livekit.android.room.SignalClient$onReadyForResponses$1$1.emit(SignalClient.kt:208) at io.livekit.android.room.SignalClient$onReadyForResponses$1$1.emit(SignalClient.kt:206) at kotlinx.coroutines.flow.SharedFlowImpl.collect$suspendImpl(SharedFlow.kt:383) at kotlinx.coroutines.flow.SharedFlowImpl.collect(Unknown Source:0) at io.livekit.android.room.SignalClient$onReadyForResponses$1.invokeSuspend(SignalClient.kt:206) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) at kotlinx.coroutines.internal.LimitedDispatcher.run(LimitedDispatcher.kt:42) at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:95) at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:570) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:749) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:677) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:664) Suppressed: kotlinx.coroutines.DiagnosticCoroutineContextException: [StandaloneCoroutine{Cancelling}@28ee7dd, Dispatchers.IO]
To Reproduce Steps to reproduce the behavior: I have a list of rooms, and I have multiple rooms, and when I switch between rooms, The main operation is to disconnect the previous room and reconnect the new room Will appear the above said exceptions: kotlin UninitializedPropertyAccessException: the subscriber from then the initialized yet.
Expected behavior How can I avoid this problem, or is there a better solution
Screenshots If applicable, add screenshots to help explain your problem.![~03V$QCA1BUB3@8I0MF LNX](https://github.com/livekit/client-sdk-android/assets/18547391/65d3d83b-651e-47c4-8af7-42ad8abb44a8)
Device Info:
Additional context Add any other context about the problem here.