Skip to content

Conversation

pablogsal
Copy link
Member

@pablogsal pablogsal commented Apr 1, 2020

Running test_socket or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.

Automerge-Triggered-By: @pablogsal

Running `test_socket` or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.
Copy link
Member

@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@miss-islington
Copy link
Contributor

@pablogsal: Status check is done, and it's a success ✅ .

@miss-islington miss-islington merged commit 6eb9619 into python:master Apr 1, 2020
@miss-islington
Copy link
Contributor

Thanks @pablogsal for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry @pablogsal, I had trouble checking out the 3.8 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 6eb9619c88612565b424be14196a8adae6d51978 3.8

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Apr 1, 2020
…pythonGH-19270)

Running `test_socket` or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.

Automerge-Triggered-By: @pablogsal
(cherry picked from commit 6eb9619)

Co-authored-by: Pablo Galindo <[email protected]>
@bedevere-bot
Copy link

GH-19271 is a backport of this pull request to the 3.7 branch.

@miss-islington
Copy link
Contributor

Thanks @pablogsal for the PR 🌮🎉.. I'm working now to backport this PR to: 3.8.
🐍🍒⛏🤖

@bedevere-bot
Copy link

GH-19272 is a backport of this pull request to the 3.8 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Apr 1, 2020
…pythonGH-19270)

Running `test_socket` or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.

Automerge-Triggered-By: @pablogsal
(cherry picked from commit 6eb9619)

Co-authored-by: Pablo Galindo <[email protected]>
miss-islington added a commit that referenced this pull request Apr 1, 2020
…GH-19270)

Running `test_socket` or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.

Automerge-Triggered-By: @pablogsal
(cherry picked from commit 6eb9619)

Co-authored-by: Pablo Galindo <[email protected]>
miss-islington added a commit that referenced this pull request Apr 1, 2020
…GH-19270)

Running `test_socket` or anything that depends on it (like python -m
test.pythoninfo) crashes if IOCTL_VM_SOCKETS_GET_LOCAL_CID does not
exist in the socket module.

Automerge-Triggered-By: @pablogsal
(cherry picked from commit 6eb9619)

Co-authored-by: Pablo Galindo <[email protected]>
@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot AMD64 Arch Linux TraceRefs 3.8 has failed when building commit 6acafee.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/313/builds/104) and take a look at the build logs.
  4. Check if the failure is related to this commit (6acafee) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/313/builds/104

Failed tests:

  • test_imaplib
  • test_urllib2_localnet
  • test_ssl

Failed subtests:

  • test_issue5949 - test.test_imaplib.ThreadedNetworkedTestsSSL
  • test_connect_cadata - test.test_ssl.SimpleBackgroundTests
  • test_ciphers - test.test_ssl.SimpleBackgroundTests
  • test_https_sni - test.test_urllib2_localnet.TestUrlopen
  • test_connect - test.test_ssl.SimpleBackgroundTests
  • test_https - test.test_urllib2_localnet.TestUrlopen
  • test_connect_capath - test.test_ssl.SimpleBackgroundTests
  • test_get_server_certificate - test.test_ssl.SimpleBackgroundTests
  • test_EOF_without_complete_welcome_message - test.test_imaplib.NewIMAPSSLTests
  • test_https_with_cafile - test.test_urllib2_localnet.TestUrlopen
  • test_session_handling - test.test_ssl.ThreadedTests
  • test_tls_unique_channel_binding - test.test_ssl.ThreadedTests
  • test_connect_with_context - test.test_ssl.SimpleBackgroundTests

Summary of the results of the build (if available):

== Tests result: FAILURE then FAILURE ==

407 tests OK.

10 slowest tests:

  • test_concurrent_futures: 2 min 23 sec
  • test_multiprocessing_spawn: 1 min 38 sec
  • test_subprocess: 1 min 14 sec
  • test_multiprocessing_forkserver: 1 min 12 sec
  • test_multiprocessing_fork: 1 min 5 sec
  • test_tokenize: 1 min
  • test_tools: 50.6 sec
  • test_asyncio: 48.7 sec
  • test_lib2to3: 40.9 sec
  • test_io: 39.8 sec

3 tests failed:
test_imaplib test_ssl test_urllib2_localnet

13 tests skipped:
test_devpoll test_ioctl test_kqueue test_msilib test_ossaudiodev
test_startfile test_tix test_tk test_ttk_guionly test_winconsoleio
test_winreg test_winsound test_zipfile64

3 re-run tests:
test_imaplib test_ssl test_urllib2_localnet

Total duration: 12 min 36 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 3917, in test_tls_unique_channel_binding
    s.connect((HOST, server.port))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1329, in _real_connect
    super().connect(addr)
ConnectionRefusedError: [Errno 111] Connection refused


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2036, in test_connect_capath
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1333, in _real_connect
    self.do_handshake()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 560, in test_https
    data = self.urlopen("https://localhost:%s/bizarre" % handler.port, context=context)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 464, in urlopen
    l.extend(f.readlines(200))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/http/client.py", line 655, in readline
    result = self.fp.readline(limit)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
ssl.SSLError: [SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:2607)


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 567, in test_https_with_cafile
    data = self.urlopen("https://localhost:%s/bizarre" % handler.port,
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 464, in urlopen
    l.extend(f.readlines(200))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/http/client.py", line 655, in readline
    result = self.fp.readline(limit)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
ssl.SSLError: [SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:2607)


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/support/__init__.py", line 2258, in decorator
    return func(*args)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_imaplib.py", line 659, in test_issue5949
    self.assertRaises(imaplib.IMAP4.abort,
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/unittest/case.py", line 816, in assertRaises
    return context.handle('assertRaises', args, kwargs)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/unittest/case.py", line 202, in handle
    callable_obj(*args, **kwargs)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1297, in __init__
    IMAP4.__init__(self, host, port)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 201, in __init__
    self._connect()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 243, in _connect
    self.welcome = self._get_response()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1050, in _get_response
    resp = self._get_line()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1158, in _get_line
    line = self.readline()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 314, in readline
    line = self.file.readline(_MAXLINE + 1)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
ssl.SSLError: [SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:2607)


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2057, in test_connect_cadata
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1333, in _real_connect
    self.do_handshake()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 1939, in test_connect
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1329, in _real_connect
    super().connect(addr)
ConnectionRefusedError: [Errno 111] Connection refused


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 4340, in test_session_handling
    s.connect((HOST, server.port))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1329, in _real_connect
    super().connect(addr)
ConnectionRefusedError: [Errno 111] Connection refused


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2115, in test_ciphers
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1333, in _real_connect
    self.do_handshake()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 601, in test_https_sni
    self.urlopen("https://localhost:%s" % handler.port, context=context)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_urllib2_localnet.py", line 464, in urlopen
    l.extend(f.readlines(200))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/http/client.py", line 655, in readline
    result = self.fp.readline(limit)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
ssl.SSLError: [SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:2607)


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2102, in test_get_server_certificate
    _test_get_server_certificate(self, *self.server_addr, cert=SIGNING_CA)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2267, in _test_get_server_certificate
    pem = ssl.get_server_certificate((host, port), ca_certs=cert)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1483, in get_server_certificate
    with  create_connection(addr) as sock:
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 808, in create_connection
    raise err
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 796, in create_connection
    sock.connect(sa)
OSError: [Errno 99] Cannot assign requested address


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 1939, in test_connect
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1333, in _real_connect
    self.do_handshake()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 3917, in test_tls_unique_channel_binding
    s.connect((HOST, server.port))
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1329, in _real_connect
    super().connect(addr)
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
   File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2386, in run
    msg = self.read()
   File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 2363, in read
    return self.sslconn.read()
   File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1101, in read
    return self._sslobj.read(len)
 OSError: [Errno 0] Error


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_ssl.py", line 1997, in test_connect_with_context
    s.connect(self.server_addr)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1342, in connect
    self._real_connect(addr, False)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1333, in _real_connect
    self.do_handshake()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ConnectionResetError: [Errno 104] Connection reset by peer


Traceback (most recent call last):
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/test/test_imaplib.py", line 251, in test_EOF_without_complete_welcome_message
    self.assertRaises(imaplib.IMAP4.abort, self.imap_class,
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/unittest/case.py", line 816, in assertRaises
    return context.handle('assertRaises', args, kwargs)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/unittest/case.py", line 202, in handle
    callable_obj(*args, **kwargs)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1297, in __init__
    IMAP4.__init__(self, host, port)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 201, in __init__
    self._connect()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 243, in _connect
    self.welcome = self._get_response()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1050, in _get_response
    resp = self._get_line()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 1158, in _get_line
    line = self.readline()
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/imaplib.py", line 314, in readline
    line = self.file.readline(_MAXLINE + 1)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/buildbot/buildarea/3.8.pablogsal-arch-x86_64/build/Lib/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
ssl.SSLError: [SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:2607)

@pablogsal pablogsal deleted the fix_test branch May 19, 2021 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip issue skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants