[Asterisk-code-review] Certify libsrtp2: Changes in Testsuite to certify libsrtp2 (testsuite[16])

Chris Savinovich asteriskteam at digium.com
Thu Nov 1 16:50:38 CDT 2018


Chris Savinovich has posted comments on this change. ( https://gerrit.asterisk.org/10580 )

Change subject: Certify_libsrtp2: Changes in Testsuite to certify libsrtp2
......................................................................


Patch Set 1:

Hi Corey. Changing line 54 from new_PYTHONPATH.append() to .insert() doesn't seem to fix the issue. 

The error I encountered was:

File "./runtests.py", line 56, in <module>
    from asterisk.asterisk import Asterisk
ImportError: No module named asterisk

In my case, the error was triggered cause sys.path.append("lib/python") puts lib/python at the end of the list:
>>> sys.path
['','/usr/lib64/python2.7/site-packages','lib/python']

whereas sys.path.insert(1,"lib/python") puts it at the front:
>>> sys.path
['','lib/python','/usr/lib64/python2.7/site-packages']

Because I also happened to have a python packaged called asterisk at /usr/lib64/python2.7/site-packages, python picked it up first, triggering the complaint. Line 56 is using the path from sys.path for the "import" command, not from new_PYTHONPATH, therefore I thought it better not to touch it.


-- 
To view, visit https://gerrit.asterisk.org/10580
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: testsuite
Gerrit-Branch: 16
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie7e7f4b1937676f033de8e7f9459594c2a7fcacc
Gerrit-Change-Number: 10580
Gerrit-PatchSet: 1
Gerrit-Owner: Chris Savinovich <csavinovich at digium.com>
Gerrit-Reviewer: Chris Savinovich <csavinovich at digium.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Jenkins2 (1000185)
Gerrit-Comment-Date: Thu, 01 Nov 2018 21:50:38 +0000
Gerrit-HasComments: No
Gerrit-HasLabels: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20181101/7f77832c/attachment.html>


More information about the asterisk-code-review mailing list