[ 
https://issues.apache.org/jira/browse/THRIFT-4430?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16297178#comment-16297178
 ] 

James E. King, III commented on THRIFT-4430:
--------------------------------------------

It sounds environmental, given our CI builds pass, for example:

https://travis-ci.org/apache/thrift/builds/318411263

The CI builds run "make check" on Ubuntu Trusty, Xenial, and Artful today using 
docker.

We build on all these python versions:
{noformat}
python  2.7.6   2.7.12  2.7.14  
python3 3.4.3   3.5.2   3.6.3
{noformat}
(see: https://github.com/apache/thrift/tree/master/build/docker)

What I would suggest is that you look at the docker files for each and see how 
python is configured.
Perhaps you have an old or missing package and it doesn't behave well?
For example on Ubuntu Xenial this is how we set up python and py3 to run thrift:
{noformat}
RUN apt-get install -y --no-install-recommends \
`# Python dependencies` \
      python-all \
      python-all-dbg \
      python-all-dev \
      python-backports.ssl-match-hostname \
      python-ipaddress \
      python-pip \
      python-setuptools \
      python-six \
      python-tornado \
      python-twisted \
      python-wheel \
      python-zope.interface \
      python3-all \
      python3-all-dbg \
      python3-all-dev \
      python3-setuptools \
      python3-six \
      python3-tornado \
      python3-twisted \
      python3-wheel \
      python3-zope.interface && \
    pip install --upgrade backports.ssl_match_hostname
{noformat}
(see: 
https://github.com/apache/thrift/blob/master/build/docker/ubuntu-xenial/Dockerfile#L202)


> Make check hangs on test_sslsocket.py
> -------------------------------------
>
>                 Key: THRIFT-4430
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4430
>             Project: Thrift
>          Issue Type: Bug
>          Components: Build Process, Test Suite
>    Affects Versions: 0.11.0
>         Environment: +OS+
> Ubuntu 16.04.1 x86_64
> Linux kernel 4.10.0-42-generic
> +Python+
> 3.6.3 |Anaconda, Inc.| (default, Oct 13 2017, 12:02:49) 
> [GCC 7.2.0]
> +make+
> GNU Make 4.1
> Built for x86_64-pc-linux-gnu
>            Reporter: Kyle Douglass
>              Labels: make, test
>
> The make check command which is run while building Thrift hangs on the 9'th 
> test in test/test_sslsocket.py. Below is the traceback I get after Ctrl-C'ing 
> after waiting on the test for ~15 minutes. Any ideas?
> {{Making check in py
> make[2]: Entering directory '/home/kmdouglass/src/thrift-0.11.0/lib/py'
> /home/kmdouglass/miniconda3/bin/python setup.py build
> running build
> running build_py
> running build_ext
> make  check-local
> make[3]: Entering directory '/home/kmdouglass/src/thrift-0.11.0/lib/py'
> /home/kmdouglass/miniconda3/bin/python setup.py build
> running build
> running build_py
> running build_ext
> /home/kmdouglass/miniconda3/bin/python test/thrift_json.py
> .
> ----------------------------------------------------------------------
> Ran 1 test in 0.000s
> OK
> /home/kmdouglass/miniconda3/bin/python test/test_sslsocket.py
> ........^CTraceback (most recent call last):
>   File "test/test_sslsocket.py", line 125, in _connectable_client
>     client = TSSLSocket(host, port, unix_socket=path, **client_kwargs)
>   File 
> "/home/kmdouglass/src/thrift-0.11.0/lib/py/build/lib.linux-x86_64-3.6/thrift/transport/TSSLS
> ocket.py", line 263, in __init__                                              
>                     
>     TSSLBase.__init__(self, False, host, kwargs)
>   File 
> "/home/kmdouglass/src/thrift-0.11.0/lib/py/build/lib.linux-x86_64-3.6/thrift/transport/TSSLS
> ocket.py", line 139, in __init__                                              
>                     
>     self._init_context(ssl_version)
>   File 
> "/home/kmdouglass/src/thrift-0.11.0/lib/py/build/lib.linux-x86_64-3.6/thrift/transport/TSSLS
> ocket.py", line 53, in _init_context                                          
>                     
>     self._context = ssl.SSLContext(ssl_version)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/ssl.py", line 391, in 
> __new__
>     self = _SSLContext.__new__(cls, protocol)
> ssl.SSLError: ('No cipher can be selected.',)
> During handling of the above exception, another exception occurred:
> Traceback (most recent call last):
>   File "test/test_sslsocket.py", line 343, in <module>
>     unittest.main()
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/main.py", line 95, 
> in __init__
>     self.runTests()
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/main.py", line 
> 256, in runTests
>     self.result = testRunner.run(self.test)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/runner.py", line 
> 176, in run
>     test(result)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/suite.py", line 
> 84, in __call__
>     return self.run(*args, **kwds)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/suite.py", line 
> 122, in run
>     test(result)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/suite.py", line 
> 84, in __call__
>     return self.run(*args, **kwds)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/suite.py", line 
> 122, in run
>     test(result)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/case.py", line 
> 653, in __call__
>     return self.run(*args, **kwds)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/unittest/case.py", line 
> 605, in run
>     testMethod()
>   File "test/test_sslsocket.py", line 291, in test_ssl2_and_ssl3_disabled
>     self._assert_connection_failure(server, ca_certs=SERVER_CERT, 
> ssl_version=ssl.PROTOCOL_SSLv2)
>   File "test/test_sslsocket.py", line 135, in _assert_connection_failure
>     with self._connectable_client(server, True, path=path, **client_args) as 
> (acc, client):
>   File "/home/kmdouglass/miniconda3/lib/python3.6/contextlib.py", line 81, in 
> __enter__
>     return next(self.gen)
>   File "test/test_sslsocket.py", line 128, in _connectable_client
>     if acc.client:
>   File "test/test_sslsocket.py", line 95, in client
>     self._client_accepted.wait()
>   File "/home/kmdouglass/miniconda3/lib/python3.6/threading.py", line 551, in 
> wait
>     signaled = self._cond.wait(timeout)
>   File "/home/kmdouglass/miniconda3/lib/python3.6/threading.py", line 295, in 
> wait
>     waiter.acquire()
> KeyboardInterrupt
> Makefile:658: recipe for target 'check-local' failed
> make[3]: *** [check-local] Error 1
> Makefile:512: recipe for target 'check-am' failed
> make[2]: *** [check-am] Interrupt
> Makefile:577: recipe for target 'check-recursive' failed
> make[1]: *** [check-recursive] Interrupt
> Makefile:660: recipe for target 'check-recursive' failed
> make: *** [check-recursive] Interrupt
> }}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to