Open projectsmindzsoft opened 1 week ago
Hi @projectsmindzsoft
Thanks for reaching out.
From the debug message I can see both the Voice SDK call-disconnected delegate, which indicates the signaling and media connections are disconnected, and the CallKit provider:performEndCallAction:
callback, which indicates CallKit has acknowledged and approved the end-call action. Together they should mean that the call was disconnected properly. When you said "the call itself does not end as expected", did you mean the call is still showing on the native call UI, or the call audio was still flowing?
Description
I am using the Twilio Voice SDK for handling incoming calls. When a call is received, the native iOS call UI appears, and I can successfully accept the call using the native UI's "Accept" button. Upon accepting, I am redirected to my app screen where I display additional call details.
However, when attempting to end the call using a custom "End Call" button inside my app, the call does not terminate. The custom button successfully triggers the appropriate delegate method, but the call remains active. It seems that while the delegate method is executed, the call itself does not end as expected.
Steps to Reproduce
Expected Behavior
The call should terminate when the custom "End Call" button is pressed, and the call should be disconnected as it would be when using the native UI to end the call.
Actual Behavior
The call remains active after pressing the custom button, even though the delegate method for ending the call is triggered. Can you please suggest us as what is wrong in above code why it is not ending call .
Reproduces How Often
Every time
Twilio Call SID(s)
You can find the Call SID in the SDK from TVOCall.sid or TVOCallInvite.callSid. The Call SID can also be found on the Twilio Calls Console: https://www.twilio.com/console/voice/calls/logs.
Logs
10.27.0 - [FirebaseMessaging][I-FCM001000] FIRMessaging Remote Notifications proxy enabled, will swizzle remote notification receiver handlers. If you'd prefer to manually integrate Firebase Messaging, add "FirebaseAppDelegateProxyEnabled" to your Info.plist, and set it to NO. Follow the instructions at: https://firebase.google.com/docs/cloud-messaging/ios/ client#method_swizzling_in_firebase_messaging to ensure proper integration. see >>>/var/mobile/Containers/Data/Application/DDBFC61F- AB54-417B-959E-07CA385053DD/Documents /var/mobile/Containers/Data/Application/DDBFC61F- AB54-417B-959E-07CA385053DD/Documents/Ribit.sqlite Database file already exist, so returning... Databse opened VoIP Push Token: ae44394bcacb1e8376c5007396fc0a34f7869f7de384c7f682644d7ee1ae6c35 Device token successfully saved in UserDefaults: e_ifoKGDWEbFv98SbXcxzn:APA91bFprWqrd3jb48ekEnroBHCwg0QH7g84-3F8R UGA5j3hYRjPBicF9G_bFz3XJ6Mj7Fec1gEHMnEDBvxY7n36ubFidUP1Tbz4Dhvj6 cG1B7MSpZ_GeQkZX1iKIKEBaV0megiGXSbQ Data deleted from table user inserted successful count of array is 0 Optional(32 bytes) DEBUG:Twilio:Platform : Using default home region INFO:Twilio:Platform : Background task started for registration/unregistration, identifer = 6 DEBUG:Twilio:Platform : Register for push notifications. DEBUG:Twilio:[Platform] (null): The default logger is used for app logs count of array is 0 count of array is 0 count of array is 0 providerDidBegin count of array is 10 DEBUG:Twilio:Platform : Completed registration request. DEBUG:Twilio:Platform : Registration location: https://ers.us1.twilio.com/v1/registrations/ cf0c8792c4e61b15eb0ea3ccf924e768 INFO:Twilio:Platform : Inside register:deviceToken:completion:, registered for Twilio push notifications. Successfully registered for VoIP push notifications.
DEBUG:Twilio:Platform : Ending registration/ unregistration background task, identifier = 6 DEBUG:Twilio:Platform : Registration/ unregistration background task ended pushRegistry:didReceiveIncomingPushWithPayload:forType:completio n: DEBUG:Twilio:Platform : Using default home region DEBUG:Twilio:Core : API Call create INFO:Twilio:Core : Creating peer connection signaling thread ... INFO:Twilio:Core : Creating peer connection worker thread ... INFO:Twilio:Core : Creating peer connection networking thread ... INFO:Twilio:Core : Creating media engine ... INFO:Twilio:Core : Done creating media engine. INFO:Twilio:Core : Creating peer connection factory ... INFO:Twilio:Core : Done creating peer connection factory. ERROR:Twilio:Platform : Cannot convert push notification payload key "aps". -[__NSDictionary0 stringValue]: unrecognized selector sent to instance 0x1e3a8c4f0 DEBUG:Twilio:Core : API Call handleMessage INFO:Twilio:Core : Creating dedicated notifier queue ... DEBUG:Twilio:Core : Selected edge - roaming Selected region - gll DEBUG:Twilio:Core : Initializing SIP stack ... DEBUG:Twilio:Core : Adding IPv4/IPv6 TLS transports ... DEBUG:Twilio:Core : Selected edge - roaming Selected region - gll INFO:Twilio:Signaling : RESIP::TRANSPORT: Connection::Connection: new connection created to who: [ V4 0.0.0.0:0 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0 ] ] INFO:Twilio:Signaling : RESIP::TRANSPORT: Creating TLS transport for domain interface= port=0 DEBUG:Twilio:Core : Selected edge - roaming Selected region - gll INFO:Twilio:Signaling : RESIP::TRANSPORT: Connection::Connection: new connection created to who: [ V4 0.0.0.0:0 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0
INFO:Twilio:Signaling : RESIP::TRANSPORT: Creating TLS transport for domain interface= port=0 DEBUG:Twilio:Core : Initializing DUM ... DEBUG:Twilio:Core : Starting SIP stack thread ... DEBUG:Twilio:Core : Starting DUM thread ... DEBUG:Twilio:Core : API Call getSignalingThread DEBUG:Twilio:Core : API Call getNetworkingThread DEBUG:Twilio:Core : API Call getNetworkingThread DEBUG:Twilio:Core : <0x10510a000> CallImpl3 signalingclient<0x2837bc3b0> DEBUG:Twilio:Core : <0x10510a000> initializeThreadCheckers DEBUG:Twilio:Core : <0x10510a000> initialize signalingclient<0x2837bc3b0> DEBUG:Twilio:Core : <0x280ebf400> Starting the Network Manager DEBUG:Twilio:Core : <0x280eb84e0> RtcMonitor DEBUG:Twilio:Core : AppleReachability::AppleReachability() DEBUG:Twilio:Core : Creating zeroAddrReachability DEBUG:Twilio:Core : API Call getFrom DEBUG:Twilio:Core : <0x10510a000> listen signalingclient<0x2837bc3b0> DEBUG:Twilio:Core : API Call getFrom DEBUG:Twilio:Core : API Call getTo DEBUG:Twilio:Core : API Call getCallSid DEBUG:Twilio:Core : API Call getFrom DEBUG:Twilio:Core : API Call getTo DEBUG:Twilio:Core : API Call getCallSid DEBUG:Twilio:Core : ListenerImpl DEBUG:Twilio:Core : Started listen no-op timer for 599999 ms DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : twilio::voice::AsyncDnsResolver::AsyncDnsResolver(std::weak_ptr< DnsResolverObserver>) DEBUG:Twilio:Core : API Call getCallSid DEBUG:Twilio:Core : API Call getTo DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : AsyncDnsResolver resolving hostname = chunderm.gll.twilio.com DEBUG:Twilio:Core : API Call getCallerInfo DEBUG:Twilio:Core : isVerified DEBUG:Twilio:Core : isVerified callInviteReceived: DEBUG:Twilio:Core : API Call getFrom
Incoming Call: from +917891667610, to client:pradeeptestone@mailinator.com, callSid CA1af6ed1eb16f3b42f76c1b1e69965473 INFO:Twilio:Platform : Inside publishConnectionEvent:, event name: incoming INFO:Twilio:Platform : Inside publishConnectionEvent:, event name: listen Incoming call successfully reported. DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : AsyncDnsResolver Resolved ip_addr = 64:ff9b::36a9:42d3, error = 0 DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : virtual void twilio::voice::SipClient::onResolveResult(twilio::voice::AsyncDn sResolver *, std::string, int) DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : onResolveResult for listen, hostname = sip:chunderm.gll.twilio.com:443;transport=tls, ip_addr = 64:ff9b::36a9:42d3 DEBUG:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : New SipCall ..., this=0x1058cc200, handle = 1 INFO:Twilio:[Core](MediaFactoryImpl::signaling 0x0x281b8df80) : Setting outbound proxy to: sip:
DEBUG:Twilio:Core : Socket created in resip/ stack/TcpBaseTransport.cxx at line 223, transport: 1, socket: 30 INFO:Twilio:Signaling : RESIP::TRANSPORT: Connection::Connection: new connection created to who: [ V6 64:ff9b::36a9:42d3 port=443 TLS target domain=64:ff9b::36a9:42d3 mFlowKey=30 ] INFO:Twilio:Signaling : RESIP::TRANSPORT: Creating TLS connection for domain [ V6 64:ff9b::36a9:42d3 port=443 TLS target domain=64:ff9b::36a9:42d3 mFlowKey=0 ] on 30 INFO:Twilio:Signaling : RESIP::TRANSPORT: TLS handshake starting (client mode) INFO:Twilio:Signaling : RESIP::TRANSPORT: TLS connected INFO:Twilio:Signaling : RESIP::TRANSPORT: TLS connected INFO:Twilio:Signaling : RESIP::TRANSPORT: TLS sessions set up with TLSv1.2 TLSv1/SSLv3 ECDHE-RSA-AES128-GCM- SHA256 INFO:Twilio:Signaling : RESIP::SIP: subjectAltName of TLS session cert contains DNS