what is TwirpErrorCode Canceled ?
# ask-ai
l
what is TwirpErrorCode Canceled ?
t
Thanks for reaching out, Deepak. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Hey there! The
TwirpErrorCode.CANCELED
in LiveKit basically means that a request or operation got canceled. This usually happens because someone (like you!) decided to stop it or because the context was canceled. It’s part of how LiveKit handles errors across its services and SDKs, including Rust, Python, and Swift. To give you an idea, in the Rust SDK, you’ll find it as a constant in the
TwirpErrorCode
enum. In the Python SDK, it shows up in the error handling inside
twirp_client.py
. And for Swift, it corresponds to the
LiveKitErrorType.cancelled
case, which also covers cancellations started by users. Oh, and sometimes this error code links to HTTP status codes like 408 (Request Timeout) or 503 (Service Unavailable), depending on what’s going on when it happens.
l
While doing call transfer using transfer_sip_participant, this error camre
t
Hey there! Could you share a bit more about the error you ran into while using
transfer_sip_participant
? For example: • What exact error message or code did you see? • Which SIP URI or phone number were you trying to transfer to? • Any extra details about your SIP trunk setup? With this info, I’ll be able to help figure out what’s going on and get you sorted out. Sources: SIP troubleshooting guide | LiveKit Docs
l
Error transferring call: TwirpError(code=canceled, message=twirp error unknown: call transfer failed, status=408)",
t
Hey there! That error
TwirpError(code=canceled, message=twirp error unknown: call transfer failed, status=408)
usually means the call transfer request took too long or was declined by the other end. It often happens because of hiccups with the SIP URI, SIP trunk setup, or how the remote endpoint is configured. Here are a few friendly tips to help you sort this out: • Double-check the SIP URI: Make sure the SIP URI or phone number you're transferring to is typed correctly and can actually be reached. • Look over the SIP Trunk Configuration: Confirm your SIP trunk is up and running with the right permissions for call transfers. Also, check that SIP REFER is turned on if your provider needs it. • Check the Remote Endpoint: See if the remote endpoint supports SIP REFER or other transfer methods and is set up to accept transfers. • Network Connectivity: Make sure there aren’t any firewall or network issues blocking the transfer request from getting through. If you’re still stuck, just share some details about the SIP URI, trunk setup, and any extra logs you have, and I’ll be happy to help you dig deeper!