]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-19756: Prevent test failures due to EADDRNOTAVAIL (GH-9446)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 20 Sep 2018 15:36:23 +0000 (08:36 -0700)
committerGitHub <noreply@github.com>
Thu, 20 Sep 2018 15:36:23 +0000 (08:36 -0700)
(cherry picked from commit 8213eaddf3ce8e87564d2949454903a1484748b5)

Co-authored-by: Berker Peksag <berker.peksag@gmail.com>
Lib/test/support/__init__.py

index 9b3ebbadfe44ceb9f4c256dff3ca7c418ba1e02e..3f1962fe1cd2b55259e7e0874b89e18ea16f6835 100644 (file)
@@ -1411,6 +1411,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),