No Audio Unless on Same WiFi

I am using react-native-webrtc to handle the WebRTC portion of this. I am using Websockets to signal and using ICE trickling to keep track of the ICE candidates.

I queue my ICE candidates until setLocalDescription has been called on the callee side. Then I addIceCandidate for each candidate in the queue.

On the caller side I am doing the same thing and not processing my ICE candidates until setRemoteDescription has been called.

I am only doing audio so no video being used.

When I test this with two mobile devices on the same network I have no issues.

But if I disconnect one device from the WiFi the calls still connect just fine except the audio cannot be heard on either device.

The onConnectionStateChange handler will still return “connected” and the onIceGatheringStateChanged will still return “complete”.

I thought maybe I needed to use a TURN server to get this working so I started using Twilio’s paid TURN/STUN server but the issue is still persisting.

Any ideas what to look into?

My ice servers include 1 STUN and 3 TURN servers (2 TCP 1 UDP).