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

(cherry picked from commit 8213eaddf3)

Co-authored-by: Berker Peksag <berker.peksag@gmail.com>
This commit is contained in:
Miss Islington (bot) 2018-09-20 08:23:45 -07:00 committed by Berker Peksag
parent 4fe8dc6857
commit 476177005e
1 changed files with 3 additions and 0 deletions

View File

@ -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),