[Python-checkins] bpo-19756: Prevent test failures due to EADDRNOTAVAIL (GH-9446)

Berker Peksag webhook-mailer at python.org
Thu Sep 20 11:23:52 EDT 2018


https://github.com/python/cpython/commit/476177005e8c8d4ece3070c8c378f8b8c068e76f
commit: 476177005e8c8d4ece3070c8c378f8b8c068e76f
branch: 3.7
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: Berker Peksag <berker.peksag at gmail.com>
date: 2018-09-20T18:23:45+03:00
summary:

bpo-19756: Prevent test failures due to EADDRNOTAVAIL (GH-9446)

(cherry picked from commit 8213eaddf3ce8e87564d2949454903a1484748b5)

Co-authored-by: Berker Peksag <berker.peksag at gmail.com>

files:
M Lib/test/support/__init__.py

diff --git a/Lib/test/support/__init__.py b/Lib/test/support/__init__.py
index 2ad563469ae3..4127b50d1fbb 100644
--- a/Lib/test/support/__init__.py
+++ b/Lib/test/support/__init__.py
@@ -1408,6 +1408,9 @@ def transient_internet(resource_name, *, timeout=30.0, errnos=()):
         ('EHOSTUNREACH', 113),
         ('ENETUNREACH', 101),
         ('ETIMEDOUT', 110),
+        # socket.create_connection() fails randomly with
+        # EADDRNOTAVAIL on Travis CI.
+        ('EADDRNOTAVAIL', 99),
     ]
     default_gai_errnos = [
         ('EAI_AGAIN', -3),



More information about the Python-checkins mailing list