[asterisk-bugs] [JIRA] (ASTERISK-24474) sip_to_pjsip.py lacks documentation and does not function

Alexander Traud (JIRA) noreply at issues.asterisk.org
Mon Sep 5 08:26:01 CDT 2016


    [ https://issues.asterisk.org/jira/browse/ASTERISK-24474?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=232145#comment-232145 ] 

Alexander Traud commented on ASTERISK-24474:
--------------------------------------------

[~johnkiniston], are you about the file {{./configs/samples/sip.conf.sample}}? If yes, that is the expected output because everything is commented in the sample file. However, if you are about your personal configuration and still face any issue, please, create a new issue report.

[~fredo], the script should remove comments within your {{sip.conf}} and continue to migrate to {{pjsip.conf}}. If that does not work in your case – I am not able to reproduce this issue yet – you found a software bug, for sure. Last month, there was a change in the configuration parser [related to comments|https://github.com/asterisk/asterisk/commits/13/contrib/scripts/sip_to_pjsip/astconfigparser.py]. Please, give it a try:
{noformat}cd ~/Downloads/
git clone --branch 13 http://gerrit.asterisk.org/asterisk
cd /etc/asterisk/
sudo ~/Downloads/asterisk/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py{noformat}

@All, the Asterisk Wiki contains a page about [migrating from chan_sip to re_pjsip|https://wiki.asterisk.org/wiki/display/AST/Migrating+from+chan_sip+to+res_pjsip], now. If you still face any issues with the migration script, please, create a new issue report.

> sip_to_pjsip.py lacks documentation and does not function
> ---------------------------------------------------------
>
>                 Key: ASTERISK-24474
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-24474
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Contrib/General
>    Affects Versions: 13.0.0-beta3
>            Reporter: John Kiniston
>            Assignee: Scott Griepentrog
>            Severity: Trivial
>      Target Release: 13.2.0, 14.0.0
>
>
> This is actually an issue against 13.0.0 however it is not listed in the Version dropdown.
> I assume I run sip_to_pjsip.py from /etc/asterisk with the input and output file as arguments as there are no instructions for this tool.
> The tool also appears to not work, Despite what the below error states I do have a udpbindaddr set to 0.0.0.0  in my configuration.
> {noformat}
> root at kiniston01:/etc/asterisk# /usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py sip.conf pjsip.conf
> Traceback (most recent call last):
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 1158, in <module>
>     pjsip, non_mappings = convert(sip, pjsip_filename, dict(), False)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 1090, in convert
>     map_transports(sip, pjsip, nmapped)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 817, in map_transports
>     create_udp(sip, pjsip, nmapped)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 590, in create_udp
>     bind = sip.multi_get('general', ['udpbindaddr', 'bindaddr'])[0]
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/astconfigparser.py", line 407, in multi_get
>     (key_list, section))
> LookupError: keys ['udpbindaddr', 'bindaddr'] not found for section 'general'
> {noformat}
> I have tried it with the sip.conf.sample file and receive the same error:
> {noformat}
> www:/tmp# /usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py sip.conf pjsip.conf
> Traceback (most recent call last):
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 1158, in <module>
>     pjsip, non_mappings = convert(sip, pjsip_filename, dict(), False)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 1090, in convert
>     map_transports(sip, pjsip, nmapped)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 817, in map_transports
>     create_udp(sip, pjsip, nmapped)
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py", line 590, in create_udp
>     bind = sip.multi_get('general', ['udpbindaddr', 'bindaddr'])[0]
>   File "/usr/src/asterisk-13.0.0/contrib/scripts/sip_to_pjsip/astconfigparser.py", line 407, in multi_get
>     (key_list, section))
> LookupError: keys ['udpbindaddr', 'bindaddr'] not found for section 'general'
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list