OpenQuizz
Une application de gestion des contenus pédagogiques
pip._vendor.urllib3.util.connection Namespace Reference

Functions

def is_connection_dropped (conn)
 
def create_connection (address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, source_address=None, socket_options=None)
 
def allowed_gai_family ()
 

Variables

 HAS_IPV6
 

Function Documentation

◆ allowed_gai_family()

def pip._vendor.urllib3.util.connection.allowed_gai_family ( )
This function is designed to work in the context of
getaddrinfo, where family=socket.AF_UNSPEC is the default and
will perform a DNS search for both IPv6 and IPv4 records.

◆ create_connection()

def pip._vendor.urllib3.util.connection.create_connection (   address,
  timeout = socket._GLOBAL_DEFAULT_TIMEOUT,
  source_address = None,
  socket_options = None 
)
Connect to *address* and return the socket object.

Convenience function.  Connect to *address* (a 2-tuple ``(host,
port)``) and return the socket object.  Passing the optional
*timeout* parameter will set the timeout on the socket instance
before attempting to connect.  If no *timeout* is supplied, the
global default timeout setting returned by :func:`socket.getdefaulttimeout`
is used.  If *source_address* is set it must be a tuple of (host, port)
for the socket to bind as a source address before making the connection.
An host of '' or port 0 tells the OS to use the default.

◆ is_connection_dropped()

def pip._vendor.urllib3.util.connection.is_connection_dropped (   conn)
Returns True if the connection is dropped and should be closed.

:param conn:
    :class:`http.client.HTTPConnection` object.

Note: For platforms like AppEngine, this will always return ``False`` to
let the platform handle connection recycling transparently for us.

Variable Documentation

◆ HAS_IPV6

HAS_IPV6