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
error in "make test", while trying to install python on linux computer #71562
Comments
I am using ubuntu 14.04, and I am trying to install a newer version of python, instead of 2.7.6 I'm trying to use 3.5.1. to do this I downloaded the tar.xz file, extracted it to a directory in my computer (not the /usr/local/bin/). I then went into the terminal and changed to the directory it was in, used $./configure, $make, $make test, and in the test it came up with an error, i then did ---------------------------------------------------------------------- OK (skipped=7) |
You need to install at least these development libraries: sudo apt-get install libssl-dev liblzma-dev libbz2-dev libreadline-dev libgdbm-dev libffi-dev Possibly some are missing in this list, tkinter and zip for example. |
the only one listed as dev was "tcl-snack-dev - Sound extension to Tcl/Tk and Python/Tkinter - development files," or instead of doing that one should i just use "python3-tk - Tkinter - Writing Tk applications with Python 3.x" and put a "-dev" at the end of the command? also, I'm a bit confused, should i only be looking at ones that have "lib" at the beginning? |
I think you need tcl8.4-dev and tk8.4-dev and perhaps zlib1g-dev. Actually the point is that it's expected that some modules don't build |
hmm, well i installed all the ones you told me to, ran make test again, and now it comes up with Traceback (most recent call last):
File "/home/rrose/temp/Python-3.5.1/Lib/test/test_nntplib.py", line 252, in wrapped
meth(self)
File "/home/rrose/temp/Python-3.5.1/Lib/test/test_nntplib.py", line 189, in test_article_head_body
self.assertEqual(filtered_lines, filtered_head_lines + [b''] + body.lines)
File "/home/rrose/temp/Python-3.5.1/Lib/unittest/case.py", line 820, in assertEqual
assertion_func(first, second, msg=msg)
File "/home/rrose/temp/Python-3.5.1/Lib/unittest/case.py", line 1018, in assertListEqual
self.assertSequenceEqual(list1, list2, msg, seq_type=list)
File "/home/rrose/temp/Python-3.5.1/Lib/unittest/case.py", line 967, in assertSequenceEqual
(i, item1, item2))
BytesWarning: str() on a bytes instance Ran 106 tests in 12.949s FAILED (errors=1) |
the test_nntplib rrose@intern:~/temp/Python-3.5.1$ ./python -m test -v test_nntplib ---------------------------------------------------------------------- OK (skipped=2) |
the test_httplib rrose@intern:~/temp/Python-3.5.1$ ./python -m test -v test_httplib ---------------------------------------------------------------------- OK (skipped=5) |
the test_ssl rrose@intern:~/temp/Python-3.5.1$ ./python -m test -v test_ssl {'OCSP': ('http://ocsp.verisign.com',), server: bad connection attempt from ('127.0.0.1', 58773):
Traceback (most recent call last):
File "/home/rrose/temp/Python-3.5.1/Lib/test/test_ssl.py", line 1789, in wrap_conn
self.sock, server_side=True)
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 376, in wrap_socket
_context=self)
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 747, in __init__
self.do_handshake()
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 983, in do_handshake
self._sslobj.do_handshake()
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 628, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: TLSV1_ALERT_UNKNOWN_CA] tlsv1 alert unknown ca (_ssl.c:645)
server: new connection from ('127.0.0.1', 34821)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
ok
test_default_ciphers (test.test_ssl.ThreadedTests) ... ok
test_default_ecdh_curve (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 47715)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
ok
test_dh_params (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 48140)
server: connection cipher is now ('DHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now None
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
ok
test_do_handshake_enotconn (test.test_ssl.ThreadedTests) ... ok
test_echo (test.test_ssl.ThreadedTests)
Basic test of an SSL client connecting to a server ...
server: new connection from ('127.0.0.1', 47352)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 52027)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 35909)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now None
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 53560)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now None
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 52272)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
ok
test_empty_cert (test.test_ssl.ThreadedTests)
Connecting with an empty cert file ...
SSLError is [SSL] PEM lib (_ssl.c:2803)
ok
test_getpeercert (test.test_ssl.ThreadedTests) ...
{'issuer': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'notAfter': 'Oct 5 23:01:56 2020 GMT',
'notBefore': 'Oct 8 23:01:56 2010 GMT',
'serialNumber': 'D7C7381919AFC24E',
'subject': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'subjectAltName': (('DNS', 'localhost'),),
'version': 3}
Connection cipher is ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1/SSLv3', 256).
ok
test_getpeercert_enotconn (test.test_ssl.ThreadedTests) ... ok
test_handshake_timeout (test.test_ssl.ThreadedTests) ... ok
test_malformed_cert (test.test_ssl.ThreadedTests)
Connecting with a badly formatted certificate (syntax error) ...
SSLError is [SSL] PEM lib (_ssl.c:2803)
ok
test_malformed_key (test.test_ssl.ThreadedTests)
Connecting with a badly formatted key (syntax error) ...
SSLError is [SSL] PEM lib (_ssl.c:2803)
ok
test_nonblocking_send (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 33178)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
Test server failure:
Traceback (most recent call last):
File "/home/rrose/temp/Python-3.5.1/Lib/test/test_ssl.py", line 1886, in run
self.write(msg.lower())
File "/home/rrose/temp/Python-3.5.1/Lib/test/test_ssl.py", line 1831, in write
return self.sslconn.write(bytes)
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 803, in write
return self._sslobj.write(data)
File "/home/rrose/temp/Python-3.5.1/Lib/ssl.py", line 581, in write
return self._sslobj.write(data)
ConnectionResetError: [Errno 104] Connection reset by peer
ok
test_nonexisting_cert (test.test_ssl.ThreadedTests)
Connecting with a non-existing cert file ...
OSError is No such file or directory
ok
test_npn_protocols (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 45702)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now http/1.1
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 56144)
client: sending b'FOO\n'...
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now http/1.1
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 50837)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now spdy/2
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 49364)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now abc
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
ok
test_protocol_sslv2 (test.test_ssl.ThreadedTests)
Connecting to an SSLv2 server with various client options ... skipped 'OpenSSL is compiled without SSLv2 support'
test_protocol_sslv23 (test.test_ssl.ThreadedTests)
Connecting to an SSLv23 server with various client options ...
{PROTOCOL_SSLv3->PROTOCOL_SSLv23} CERT_NONE
PROTOCOL_SSLv23->PROTOCOL_SSLv23 CERT_NONE
PROTOCOL_TLSv1->PROTOCOL_SSLv23 CERT_NONE
{PROTOCOL_SSLv3->PROTOCOL_SSLv23} CERT_OPTIONAL
PROTOCOL_SSLv23->PROTOCOL_SSLv23 CERT_OPTIONAL
PROTOCOL_TLSv1->PROTOCOL_SSLv23 CERT_OPTIONAL
{PROTOCOL_SSLv3->PROTOCOL_SSLv23} CERT_REQUIRED
PROTOCOL_SSLv23->PROTOCOL_SSLv23 CERT_REQUIRED
PROTOCOL_TLSv1->PROTOCOL_SSLv23 CERT_REQUIRED
{PROTOCOL_SSLv3->PROTOCOL_SSLv23} CERT_NONE
PROTOCOL_SSLv23->PROTOCOL_SSLv23 CERT_NONE
{PROTOCOL_TLSv1->PROTOCOL_SSLv23} CERT_NONE
ok
test_protocol_sslv3 (test.test_ssl.ThreadedTests)
Connecting to an SSLv3 server with various client options ...
PROTOCOL_SSLv3->PROTOCOL_SSLv3 CERT_NONE
PROTOCOL_SSLv3->PROTOCOL_SSLv3 CERT_OPTIONAL
PROTOCOL_SSLv3->PROTOCOL_SSLv3 CERT_REQUIRED
{PROTOCOL_SSLv23->PROTOCOL_SSLv3} CERT_NONE
{PROTOCOL_TLSv1->PROTOCOL_SSLv3} CERT_NONE
{PROTOCOL_SSLv23->PROTOCOL_SSLv3} CERT_NONE
ok
test_protocol_tlsv1 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1 server with various client options ...
PROTOCOL_TLSv1->PROTOCOL_TLSv1 CERT_NONE
PROTOCOL_TLSv1->PROTOCOL_TLSv1 CERT_OPTIONAL
PROTOCOL_TLSv1->PROTOCOL_TLSv1 CERT_REQUIRED
{PROTOCOL_SSLv3->PROTOCOL_TLSv1} CERT_NONE
{PROTOCOL_SSLv23->PROTOCOL_TLSv1} CERT_NONE
ok
test_protocol_tlsv1_1 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1.1 server with various client options. ...
PROTOCOL_TLSv1_1->PROTOCOL_TLSv1_1 CERT_NONE
{PROTOCOL_SSLv3->PROTOCOL_TLSv1_1} CERT_NONE
{PROTOCOL_SSLv23->PROTOCOL_TLSv1_1} CERT_NONE
PROTOCOL_TLSv1_1->PROTOCOL_SSLv23 CERT_NONE
{PROTOCOL_TLSv1->PROTOCOL_TLSv1_1} CERT_NONE
{PROTOCOL_TLSv1_1->PROTOCOL_TLSv1} CERT_NONE
ok
test_protocol_tlsv1_2 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1.2 server with various client options. ...
PROTOCOL_TLSv1_2->PROTOCOL_TLSv1_2 CERT_NONE
{PROTOCOL_SSLv3->PROTOCOL_TLSv1_2} CERT_NONE
{PROTOCOL_SSLv23->PROTOCOL_TLSv1_2} CERT_NONE
PROTOCOL_TLSv1_2->PROTOCOL_SSLv23 CERT_NONE
{PROTOCOL_TLSv1->PROTOCOL_TLSv1_2} CERT_NONE
{PROTOCOL_TLSv1_2->PROTOCOL_TLSv1} CERT_NONE
{PROTOCOL_TLSv1_1->PROTOCOL_TLSv1_2} CERT_NONE
{PROTOCOL_TLSv1_2->PROTOCOL_TLSv1_1} CERT_NONE
ok
test_read_write_after_close_raises_valuerror (test.test_ssl.ThreadedTests) ... ok
test_recv_send (test.test_ssl.ThreadedTests)
Test recv(), send() and friends. ...
server: new connection from ('127.0.0.1', 37197)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
ok
test_rude_shutdown (test.test_ssl.ThreadedTests)
A brutal shutdown of an SSL server should raise an OSError ... ok
test_selected_alpn_protocol (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 55355)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now None
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
ok
test_selected_alpn_protocol_if_server_uses_alpn (test.test_ssl.ThreadedTests) ... skipped 'ALPN support required'
test_selected_npn_protocol (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 57433)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
client: sending b'FOO\n'...
server: selected protocol is now None
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: sending b'FOO\n'...
client: read b'foo\n'
client: closing connection.
ok
test_sendfile (test.test_ssl.ThreadedTests) ... ok
test_server_accept (test.test_ssl.ThreadedTests) ... ok
test_shared_ciphers (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 44231)
server: connection cipher is now ('ECDHE-RSA-RC4-SHA', 'TLSv1/SSLv3', 128)
server: selected protocol is now None
ok
test_sni_callback (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 37285)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
server: new connection from ('127.0.0.1', 56968)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
server: new connection from ('127.0.0.1', 34528)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
ok
test_sni_callback_alert (test.test_ssl.ThreadedTests) ... ok
test_sni_callback_raising (test.test_ssl.ThreadedTests) ... ok
test_sni_callback_wrong_return_type (test.test_ssl.ThreadedTests) ... ok
test_socketserver (test.test_ssl.ThreadedTests)
Using a SocketServer to create and manage SSL connections. ...
server (('127.0.0.1', 36048):36048 ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1/SSLv3', 256)):
[23/Jun/2016 15:20:36] "GET /keycert.pem HTTP/1.1" 200 -
client: read 1783 bytes from remote server '<HTTPSServerThread <HTTPSServer localhost:36048>>'
stopping HTTPS server
joining HTTPS thread
ok
test_starttls (test.test_ssl.ThreadedTests)
Switching from clear text to encrypted and back again. ...
client: sending b'msg 1'...
server: new connection from ('127.0.0.1', 33860)
server: read b'msg 1' (unencrypted), sending back b'msg 1' (unencrypted)...
client: read b'msg 1' from server
client: sending b'MSG 2'...
server: read b'MSG 2' (unencrypted), sending back b'msg 2' (unencrypted)...
client: read b'msg 2' from server
client: sending b'STARTTLS'...
server: read STARTTLS from client, sending OK...
client: read b'ok' from server, starting TLS...
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
client: sending b'MSG 3'...
server: read b'MSG 3' (encrypted), sending back b'msg 3' (encrypted)...
client: read b'msg 3' from server
client: sending b'msg 4'...
server: read b'msg 4' (encrypted), sending back b'msg 4' (encrypted)...
client: read b'msg 4' from server
client: sending b'ENDTLS'...
server: read ENDTLS from client, sending OK...
client: read b'ok' from server, ending TLS...
server: connection is now unencrypted...
client: sending b'msg 5'...
server: read b'msg 5' (unencrypted), sending back b'msg 5' (unencrypted)...
client: read b'msg 5' from server
client: sending b'msg 6'...
server: read b'msg 6' (unencrypted), sending back b'msg 6' (unencrypted)...
client: read b'msg 6' from server
client: closing connection.
server: client closed connection
ok
test_tls_unique_channel_binding (test.test_ssl.ThreadedTests)
Test tls-unique channel binding. ...
server: new connection from ('127.0.0.1', 43512)
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
got channel binding data: b'\xdf\xfa\xed\x05gGz0\xe5\xa5fP'
server: selected protocol is now None
server: new connection from ('127.0.0.1', 43513)
got another channel binding data: b'\xe4\xc1\xfb\xbaW\xe32\x85\xea:$T'
server: connection cipher is now ('ECDHE-RSA-AES256-SHA', 'TLSv1/SSLv3', 256)
server: selected protocol is now None
ok
test_version_basic (test.test_ssl.ThreadedTests) ... ok Ran 100 tests in 1.347s OK (skipped=7) |
also, after installing this library liblzma-dev it said that i had redundant files (not in those words) and that I should run "apt-get autoremove," which I did, this may have been what caused the other failures? |
Ah, so the tests pass when you run them manually but "make test" https://bugs.python.org/issue26837 , which is fixed in the next release. You can just ignore this [BTW, using autoremove is fine.] |
ok great, thanks for your help! |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: