twilio/voice-quickstart-objc

Client sometimes doesn't receive call invite push notifications from Twilio

Closed this issue · 5 comments

aryo commented

Before filing an issue please check that the issue is not already addressed by the following:

Description

Client device sometimes doesn't receive call invite push notifications from Twilio (twilio.voice.call message type), thus not getting incoming calls. We have our own push notifications that get sent to the device that contains metadata around the call, and those are received successfully, so it doesn't seem like a device issue.

Sometimes the duration of the issue will last for a while (a couple hours), and sometimes a couple minutes.

In one instance (call sid: CA71e437a63fb85ab92e5714cad9629d75), the device didn't get the invite push notification but got the twilio.voice.cancel one not too long after.

Steps to Reproduce

  1. Call a certain client
  2. Nothing happens

Expected Behavior

Client receives twilio.voice.call push notification so it can see that there's an incoming call.

Actual Behavior

Client doesn't receive any push notifications from Twilio

Reproduces How Often

3-5%

Versions

All relevant version information for the issue.

Voice iOS SDK

2.0.2 via CocoaPods

Xcode

9.1

iOS Version

11.0

iOS Device

iPhone 6s

Hi @aryo

Thanks for reporting the issue with great descriptions!
I've checked the Call SID but unfortunately the last status of the call is canceled and that's probably the reason why the callee never received the incoming call notification. (and yes, the cancel notification will still be sent to all the client registered with that identity)

To further debug the issue we need your help:

  1. Can you tell us how the calls are made? I am assuming they are made from one mobile client to another mobile client, and the TwiML is as simple as dialing to a client, right?
  2. We need more Call SIDs to see if there are more than one possible root cause of the issue. In the meantime you can also check out the Programmable Voice Dashboard and you should see some errors being logged with some helpful information.

Thanks
-bobie

aryo commented

Thanks for the quick reply @bchen-twilio.

We have a timeout of 30 seconds, so if the call is not picked up in 30 seconds, we cancel the call. The issue is that the call notification never reaches the client.

So in that particular instance where I provided the Call SID, we're actually routing a parent incoming call (call sid: CAd161642415052763e3d77fbcd69bbe0e) and we sent an invite to join that call to 2 separate clients (Client A: with Call sid of CA16468cac6948ecdd994f055da547fa58; and Client B: with Call sid of CA71e437a63fb85ab92e5714cad9629d75). Both clients never got the call notifications, and only Client B got the cancel notification.

Here's a call made from mobile client to mobile client where the recipient didn't get a call notification either: CA6ac56f7c3e5015e0390aa57ceafc357e. Later on, made another call (same initiator & recipient) and it worked again, the recipient got the call notification: CAe97e2108b7db84023dde74df6ea9ec4c.

Hi @aryo

Thanks for providing extra info of the calls.
Though my access to the debug tools of Twilio Notify service is limited, I still managed to grab some logs from their DB.

Based on the logs associated to the Call SIDs, I can't find any errors being logged. All notification delivery attempts were successful, which means the request from the Notify service to either Apple or the FCM services are successfully fulfilled.

I am afraid that further debugging is out of my area but I've passed the Call SIDs to the backend team so they can do some diagnosis. Please stay tuned.

thanks
-bobie

aryo commented

closed due to being no longer relevant. i know it's late, but thanks for the help bobie.

@aryo would you mind sharing how you fixed this issue?