Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions Lib/test/test_ssl.py
Original file line number Diff line number Diff line change
Expand Up @@ -5698,15 +5698,18 @@ def non_linux_skip_if_other_okay_error(self, err):
return # Expect the full test setup to always work on Linux.
if (isinstance(err, (ConnectionResetError, ConnectionAbortedError)) or
(isinstance(err, OSError) and err.errno == errno.EINVAL) or
re.search('wrong.version.number', str(getattr(err, "reason", "")), re.I) or
re.search('record.layer.failure', str(getattr(err, "reason", "")), re.I)
re.search(
r'wrong.version.number|record.layer.failure|http.request',
str(getattr(err, "reason", "")),
re.I
)
):
# On Windows the TCP RST leads to a ConnectionResetError
# (ECONNRESET) which Linux doesn't appear to surface to userspace.
# If wrap_socket() winds up on the "if connected:" path and doing
# the actual wrapping... we get an SSLError from OpenSSL. This is
# typically WRONG_VERSION_NUMBER. The same happens on iOS, but
# RECORD_LAYER_FAILURE is the error.
# RECORD_LAYER_FAILURE or HTTP_REQUEST is the error.
#
# While appropriate, neither is the scenario we're specifically
# trying to test. The way this test is written is known to work on
Expand Down
2 changes: 1 addition & 1 deletion Platforms/Apple/testbed/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
LOG_PREFIX_REGEX = re.compile(
r"^\d{4}-\d{2}-\d{2}" # YYYY-MM-DD
r"\s+\d+:\d{2}:\d{2}\.\d+\+\d{4}" # HH:MM:SS.ssssss+ZZZZ
r"\s+iOSTestbed\[\d+:\w+\]" # Process/thread ID
r"\s+iOSTestbed\[\d+:\w+\] " # Process/thread ID
)


Expand Down
Loading