Closed javyduty closed 2 years ago
Hi @javyduty
CallKit request error 4 typically means the UUID submitted in the request does not match anything that was previous reported to CallKit. Please check if the call UUID was properly reported to CallKit. The quickstart should provide a good example of such process.
By the way, does this happen when the incoming call is hung up by the caller or by the local client?
Thanks for the response @bobiechen-twilio, it happens when hanging up from the local client (the person who answered the call) Hanging up works when using Call Kit (opening the recent apps and hanging up from the Call Kit view). It also works when hanging up from the caller. At times it is the only way to hang up.
Thanks @javyduty. In that case I think this flag might help: https://github.com/twilio/voice-quickstart-ios/blob/master/SwiftVoiceQuickstart/ViewController.swift#L133
Would that need to be switched to false, since the person is receiving the call rather than the one initiating it?
We added the flag to differentiate the case when the disconnect is initiated via application UI, from the case when the disconnect happens from CallKit. In general you will want to make sure the disconnect procedure goes through the CallKit request and update call UUIDs consistently.
Thanks, I will try that and let you know.
I tried that but still no luck, I went a different route and had to move everything to a singleton and set the delegate in the view that I was calling. It now hangs up as expected. Just thought I would post in case anyone else ran into the same issue. Thanks for the help!
Description
When a call comes in from a push notification the delegate handles the call and changes the root view controller to the a call view controller (as expected). When trying to hang up the call using the
performEndCallAction
function I get the following errorcom.apple.CallKit.error.requesttransaction error 4.
I have verified that the call uuid matches everywhere and have ensured there are no nils.Steps to Reproduce
Code
Expected Behavior
call hangs up
Actual Behavior
Get this error
com.apple.CallKit.error.requesttransaction error 4.
Call is not working (can't hear or speak) but the call is still active (green indicator in corner)Reproduces How Often
100%
Twilio Call SID(s)
CAe8e6ac6e7720850bf934d108e07f5ed1 CA66eab086af8feb32270f31692cf54c8a
CA8e9722adb056e49ec75ca6b75de16430 CA41dc1b81c23e5fb6a80a8cad59620298
Logs
Versions
Swift: 5.4
Voice iOS SDK
6.3.1
Xcode
Xcode: Version 13.2.1
iOS Version
iOS 15
iOS Device
iPhone X - Two of them Simulator