Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Couldn't Terminate a Call #1

Closed
mattwilliamson opened this issue May 27, 2011 · 5 comments
Closed

Couldn't Terminate a Call #1

mattwilliamson opened this issue May 27, 2011 · 5 comments
Assignees

Comments

@mattwilliamson
Copy link
Contributor

This is the log in the REST server:

2011-05-27 17:51:54,588 apiserver[34070]: INFO: Executed Call hangup for RequestUUID dc196591-5433-488b-ae6b-e4f2ca794b2b
2011-05-27 17:51:54,588 apiserver[34070]: INFO: 127.0.0.1 - - [2011-05-27 17:51:54] "POST /v0.1/HangupCall/ HTTP/1.1" 200 58 "-" "Python-urllib/2.6"

No error, but call kept going.

@mike-plivo
Copy link
Member

thanks for the report.
I just commited change for HangupCall : more logs and more checks

Some questions :
Do you run HangupCall using an helper like plivohelper-python ?
Do you run HangupCall with CallUUID or RequestUUID ?

Thanks !

@ghost ghost assigned mike-plivo May 28, 2011
@mattwilliamson
Copy link
Contributor Author

I ran HangupCall using plivohelper-python on the CallUUID manually by copying from the following outbound server log (REST Server log below that):

Outbound Server

2011-05-28 10:49:41,695 outboundserver[65617]: INFO: (1) New request from ('127.0.0.1', 51255)
2011-05-28 10:49:41,696 outboundserver[65617]: DEBUG: (1) Execute: connect args=''
2011-05-28 10:49:41,706 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Event-Name: CHANNEL_DATA\nCore-UUID: b05c8cb2-5241-4392-bef1-493c9a68498d\nFreeSWITCH-Hostname: goliath.local\nFreeSWITCH-Switchname: goliath.local\nFreeSWITCH-IPv4: 192.168.1.77\nFreeSWITCH-IPv6: ::1\nEvent-Date-Local: 2011-05-28 10:49:41\nEvent-Date-GMT: Sat, 28 May 2011 14:49:41 GMT\nEvent-Date-Timestamp: 1306594181688909\nEvent-Calling-File: mod_event_socket.c\nEvent-Calling-Function: parse_command\nEvent-Calling-Line-Number: 1843\nChannel-Direction: inbound\nChannel-Username: 7322761300\nChannel-Dialplan: XML\nChannel-Caller-ID-Name: LAKEWOOD NJ\nChannel-Caller-ID-Number: 7322761300\nChannel-Network-Addr: 66.54.140.46\nChannel-ANI: 7322761300\nChannel-Destination-Number: matt_teltech\nChannel-Unique-ID: 42a3b25b-90d8-45cc-a268-2096db1af706\nChannel-Source: mod_sofia\nChannel-Context: public\nChannel-Channel-Name: sofia/internal/7322761300@66.54.140.46\nChannel-Profile-Index: 1\nChannel-Profile-Created-Time: 1306594181663173\nChannel-Channel-Created-Time: 1306594181663173\nChannel-Channel-Answered-Time: 0\nChannel-Channel-Progress-Time: 0\nChannel-Channel-Progress-Media-Time: 0\nChannel-Channel-Hangup-Time: 0\nChannel-Channel-Transfer-Time: 0\nChannel-Screen-Bit: true\nChannel-Privacy-Hide-Name: false\nChannel-Privacy-Hide-Number: false\nChannel-State: CS_EXECUTE\nChannel-Call-State: RINGING\nChannel-State-Number: 4\nChannel-Name: sofia/internal/7322761300@66.54.140.46\nUnique-ID: 42a3b25b-90d8-45cc-a268-2096db1af706\nCall-Direction: inbound\nPresence-Call-Direction: inbound\nChannel-Presence-ID: 7322761300@66.54.140.46\nAnswer-State: ringing\nChannel-Read-Codec-Name: PCMU\nChannel-Read-Codec-Rate: 8000\nChannel-Read-Codec-Bit-Rate: 64000\nChannel-Write-Codec-Name: PCMU\nChannel-Write-Codec-Rate: 8000\nChannel-Write-Codec-Bit-Rate: 64000\nCaller-Direction: inbound\nCaller-Username: 7322761300\nCaller-Dialplan: XML\nCaller-Caller-ID-Name: LAKEWOOD NJ\nCaller-Caller-ID-Number: 7322761300\nCaller-Network-Addr: 66.54.140.46\nCaller-ANI: 7322761300\nCaller-Destination-Number: matt_teltech\nCaller-Unique-ID: 42a3b25b-90d8-45cc-a268-2096db1af706\nCaller-Source: mod_sofia\nCaller-Context: public\nCaller-Channel-Name: sofia/internal/7322761300@66.54.140.46\nCaller-Profile-Index: 1\nCaller-Profile-Created-Time: 1306594181663173\nCaller-Channel-Created-Time: 1306594181663173\nCaller-Channel-Answered-Time: 0\nCaller-Channel-Progress-Time: 0\nCaller-Channel-Progress-Media-Time: 0\nCaller-Channel-Hangup-Time: 0\nCaller-Channel-Transfer-Time: 0\nCaller-Screen-Bit: true\nCaller-Privacy-Hide-Name: false\nCaller-Privacy-Hide-Number: false\nvariable_direction: inbound\nvariable_uuid: 42a3b25b-90d8-45cc-a268-2096db1af706\nvariable_sip_local_network_addr: 69.124.21.164\nvariable_sip_network_ip: 66.54.140.46\nvariable_sip_network_port: 5060\nvariable_sip_received_ip: 66.54.140.46\nvariable_sip_received_port: 5060\nvariable_sip_via_protocol: udp\nvariable_sip_authorized: true\nvariable_sip_acl_authed_by: domains\nvariable_sip_from_user: 7322761300\nvariable_sip_from_uri: 7322761300@66.54.140.46\nvariable_sip_from_host: 66.54.140.46\nvariable_sip_from_user_stripped: 7322761300\nvariable_sip_from_tag: as3a164d8b\nvariable_sofia_profile_name: internal\nvariable_sip_full_via: SIP/2.0/UDP 66.54.140.46:5060;branch=z9hG4bK2ad318db;rport=5060\nvariable_sip_from_display: LAKEWOOD NJ\nvariable_sip_full_from: "LAKEWOOD NJ" <sip:7322761300@66.54.140.46>;tag=as3a164d8b\nvariable_sip_full_to: <sip:matt_teltech@69.124.21.164>\nvariable_sip_req_user: matt_teltech\nvariable_sip_req_uri: matt_teltech@69.124.21.164\nvariable_sip_req_host: 69.124.21.164\nvariable_sip_to_user: matt_teltech\nvariable_sip_to_uri: matt_teltech@69.124.21.164\nvariable_sip_to_host: 69.124.21.164\nvariable_sip_contact_user: 7322761300\nvariable_sip_contact_uri: 7322761300@66.54.140.46\nvariable_sip_contact_host: 66.54.140.46\nvariable_channel_name: sofia/internal/7322761300@66.54.140.46\nvariable_sip_call_id: 113e417d421e4d2b2671c4325eaffcb5@66.54.140.46\nvariable_sip_user_agent: IPKall\nvariable_sip_via_host: 66.54.140.46\nvariable_sip_via_port: 5060\nvariable_sip_via_rport: 5060\nvariable_ma\n\nvariable_remote_media_ip: 66.54.140.46\nvariable_remote_media_port: 21904\nvariable_sip_audio_recv_pt: 0\nvariable_sip_use_codec_name: PCMU\nvariable_sip_use_codec_rate: 8000\nvariable_sip_use_codec_ptime: 20\nvariable_read_codec: PCMU\nvariable_read_rate: 8000\nvariable_write_codec: PCMU\nvariable_write_rate: 8000\nvariable_endpoint_disposition: RECEIVED\nvariable_outside_call: true\nvariable_RFC2822_DATE: Sat, 28 May 2011 10:49:41 -0400\nvariable_domain_name: 192.168.1.77\nvariable_current_application_data: 127.0.0.1:8084 async full\nvariable_current_application: socket\nvariable_socket_host: 127.0.0.1\nContent-Type: command/reply\nReply-Text: +OK\n\nSocket-Mode: async\nControl: full\n, body=>
2011-05-28 10:49:41,707 outboundserver[65617]: DEBUG: (1) Execute: event plain args='CHANNEL_EXECUTE_COMPLETE CHANNEL_HANGUP CUSTOM'
2011-05-28 10:49:41,733 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK event listener enabled plain\n, body=>
2011-05-28 10:49:41,733 outboundserver[65617]: DEBUG: (1) Execute: resume args=''
2011-05-28 10:49:41,743 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:49:41,746 outboundserver[65617]: DEBUG: (1) Execute: filter args='Unique-ID 42a3b25b-90d8-45cc-a268-2096db1af706'
2011-05-28 10:49:41,746 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK filter added. [Unique-ID]=[42a3b25b-90d8-45cc-a268-2096db1af706]\n, body=>
2011-05-28 10:49:41,747 outboundserver[65617]: DEBUG: (1) Execute: linger args=''
2011-05-28 10:49:41,751 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK will linger\n, body=>
2011-05-28 10:49:41,751 outboundserver[65617]: DEBUG: (1) Execute: set args=plivo_app=true, uuid='', lock=True, loops=1
2011-05-28 10:49:41,752 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:49:41,752 outboundserver[65617]: DEBUG: (1) Execute: set args=hangup_after_bridge=false, uuid='', lock=True, loops=1
2011-05-28 10:49:41,754 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:49:41,754 outboundserver[65617]: DEBUG: (1) Execute: api args='uuid_getvar 42a3b25b-90d8-45cc-a268-2096db1af706 plivo_transfer_url'
2011-05-28 10:49:41,757 outboundserver[65617]: DEBUG: (1) Response: <ApiResponse headers=Content-Type: api/response\nContent-Length: 7\n, body=_undef_>
2011-05-28 10:49:41,757 outboundserver[65617]: DEBUG: (1) Execute: api args='uuid_getvar 42a3b25b-90d8-45cc-a268-2096db1af706 plivo_answer_url'
2011-05-28 10:49:41,768 outboundserver[65617]: DEBUG: (1) Response: <ApiResponse headers=Content-Type: api/response\nContent-Length: 7\n, body=_undef_>
2011-05-28 10:49:41,768 outboundserver[65617]: INFO: (1) Using DefaultAnswerUrl http://127.0.0.1:5000/_plivo/answered/
2011-05-28 10:49:41,768 outboundserver[65617]: DEBUG: (1) Execute: api args='uuid_getvar 42a3b25b-90d8-45cc-a268-2096db1af706 plivo_sched_hangup_id'
2011-05-28 10:49:41,822 outboundserver[65617]: DEBUG: (1) Response: <ApiResponse headers=Content-Type: api/response\nContent-Length: 7\n, body=_undef_>
2011-05-28 10:49:41,823 outboundserver[65617]: DEBUG: (1) Execute: api args='uuid_getvar 42a3b25b-90d8-45cc-a268-2096db1af706 plivo_hangup_url'
2011-05-28 10:49:41,824 outboundserver[65617]: DEBUG: (1) Response: <ApiResponse headers=Content-Type: api/response\nContent-Length: 7\n, body=_undef_>
2011-05-28 10:49:41,824 outboundserver[65617]: INFO: (1) Processing Call
2011-05-28 10:49:41,824 outboundserver[65617]: INFO: (1) Fetching RESTXML from http://127.0.0.1:5000/_plivo/answered/ with {}
2011-05-28 10:49:41,992 outboundserver[65617]: INFO: (1) Sent to POST http://127.0.0.1:5000/_plivo/answered/ with {'To': 'matt_teltech', 'Direction': 'inbound', 'From': '7322761300', 'CallUUID': '42a3b25b-90d8-45cc-a268-2096db1af706', 'CallStatus': 'ringing'} -- Result: <Response><Speak loop="1" voice="slt">Welcome to your new Telapia Account.</Speak><Wait length="60"/><Speak loop="1" voice="slt">Let us know if we can help you in any way during your development.</Speak><Wait length="60"/></Response>
2011-05-28 10:49:41,992 outboundserver[65617]: INFO: (1) Requested RESTXML to http://127.0.0.1:5000/_plivo/answered/ with {'To': 'matt_teltech', 'Direction': 'inbound', 'From': '7322761300', 'CallUUID': '42a3b25b-90d8-45cc-a268-2096db1af706', 'CallStatus': 'ringing'}
2011-05-28 10:49:41,993 outboundserver[65617]: DEBUG: (1) Answering because Element Speak need it
2011-05-28 10:49:41,993 outboundserver[65617]: DEBUG: (1) Execute: answer args=, uuid='', lock=True, loops=1
2011-05-28 10:49:41,997 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:49:41,997 outboundserver[65617]: INFO: (1) [Speak] Welcome to your new Telapia Account. {'engine': 'flite', 'language': 'en', 'voice': 'slt', 'type': '', 'method': '', 'loop': '1'}
2011-05-28 10:49:41,997 outboundserver[65617]: DEBUG: (1) Execute: speak args=flite|slt|Welcome to your new Telapia Account., uuid='', lock=True, loops=1
2011-05-28 10:49:42,007 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:49:44,807 outboundserver[65617]: INFO: (1) Speak 1 times - (_none_)
2011-05-28 10:49:44,807 outboundserver[65617]: INFO: (1) [Speak] Done
2011-05-28 10:49:44,807 outboundserver[65617]: INFO: (1) [Wait]  {'length': '60'}
2011-05-28 10:49:44,807 outboundserver[65617]: INFO: (1) Wait Started for 60 seconds
2011-05-28 10:49:44,811 outboundserver[65617]: DEBUG: (1) Execute: sleep args=60000, uuid='', lock=False, loops=1
2011-05-28 10:49:44,837 outboundserver[65617]: DEBUG: (1) Response: <CommandResponse headers=Content-Type: command/reply\nReply-Text: +OK\n, body=>
2011-05-28 10:50:07,869 outboundserver[65617]: INFO: (1) Event: channel 42a3b25b-90d8-45cc-a268-2096db1af706 has hung up (NORMAL_CLEARING)
2011-05-28 10:50:07,869 outboundserver[65617]: INFO: (1) Sending hangup to http://127.0.0.1:5000/hangup/
2011-05-28 10:50:07,882 outboundserver[65617]: ERROR: (1) Sending to POST http://127.0.0.1:5000/hangup/ with {'To': 'matt_teltech', 'Direction': 'inbound', 'From': '7322761300', 'CallUUID': '42a3b25b-90d8-45cc-a268-2096db1af706', 'HangupCause': 'NORMAL_CLEARING', 'CallStatus': 'completed'} -- Error: HTTP Error 404: NOT FOUND
2011-05-28 10:50:07,895 outboundserver[65617]: INFO: (1) [Wait] Done
2011-05-28 10:50:07,896 outboundserver[65617]: INFO: (1) [Speak] Let us know if we can help you in any way during your development. {'engine': 'flite', 'language': 'en', 'voice': 'slt', 'type': '', 'method': '', 'loop': '1'}
2011-05-28 10:50:07,896 outboundserver[65617]: DEBUG: (1) Execute: speak args=flite|slt|Let us know if we can help you in any way during your development., uuid='', lock=True, loops=1

REST Server:

2011-05-28 10:50:02,114 apiserver[65060]: ERROR: Call Hangup Failed -- RequestUUID 42a3b25b-90d8-45cc-a268-2096db1af706 not found
2011-05-28 10:50:02,114 apiserver[65060]: INFO: 127.0.0.1 - - [2011-05-28 10:50:02] "POST /v0.1/HangupCall/ HTTP/1.1" 200 57 "-" "Python-urllib/2.6"

@mattwilliamson
Copy link
Contributor Author

Also, please note I was trying to hangup while it was inside of the Wait command for 60 seconds.

@mattwilliamson
Copy link
Contributor Author

Ah I think I have it! I copied and pasted from the example-call.py in olivohelper-python and I'm posting the RequestUUID instead of the CallUUID. Let me see if changing that fixes it.

@mattwilliamson
Copy link
Contributor Author

That worked! Thank you for putting in the log messages so I could figure out what was happening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants