react-native-twilio-video-webrtc icon indicating copy to clipboard operation
react-native-twilio-video-webrtc copied to clipboard

Microphone indicator (orange dot) after disconnect()

Open romust opened this issue 3 years ago • 5 comments

Steps to reproduce

  1. disconnect()

Expected behaviour

There is no dot at the top of the screen.

Actual behaviour

The green dot disappears then the orange dot shows up and stays there until reloading the app. This issue is similar to https://github.com/blackuy/react-native-twilio-video-webrtc/issues/396 (which was fixed but only for the green dot, not for the orange one) I guess the microphone instance is still active after the disconnect

Environment

  • Node.js version: 14.17.6
  • React Native version: 0.65.1
  • React Native platform + platform version: iOS 15.1

react-native-twilio-video-webrtc

Version: npm version 2.0.0

romust avatar Dec 03 '21 11:12 romust

Just to help me debug the issue, does the dot go away if you call twilioVideo.ref._stopLocalAudio() on iOS?

slycoder avatar Feb 21 '22 20:02 slycoder

I also faced this issue. The reason is you are not disconnecting the audio track. You can check this with twilio video console. Audio track will be still connected. Use a separate button to call ref.current.disconnect() method if you call it on componentDidUnmount/ useEffect return. Reason may be the ref is already undefined or null when you calling ref.current.disconnect().

Shenith avatar Mar 15 '22 13:03 Shenith

Just to help me debug the issue, does the dot go away if you call twilioVideo.ref._stopLocalAudio() on iOS?

No the does it still there.

oliviermtl avatar Oct 19 '22 02:10 oliviermtl

I also faced this issue. The reason is you are not disconnecting the audio track. You can check this with twilio video console. Audio track will be still connected. Use a separate button to call ref.current.disconnect() method if you call it on componentDidUnmount/ useEffect return. Reason may be the ref is already undefined or null when you calling ref.current.disconnect().

If you call ref.current.disconnect() it should close the audio track as well, in this case it does not.

oliviermtl avatar Oct 19 '22 02:10 oliviermtl

I got exactly same problem, but in case app waked from killed state. Other case work fine, do you have any solution?

fukemy avatar Oct 25 '22 09:10 fukemy