Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)
Convert IP string to IPv4 string

        def to_ipv4(addr):
    """Convert IP string to IPv4 string"""
    if is_ipv4(addr):
        return addr
    return ipv6_to_ipv4(addr)

src/b/i/BitTornado-HEAD/BitTornado/BT1/track.py   BitTornado(Download)
import threading
from urllib import quote, unquote
from BitTornado.NetworkAddress import is_ipv4, is_valid_ip, ipv6_to_ipv4, \
    to_ipv4, AddrList
from BitTornado.parseargs import parseargs, formatDefinitions
            ip = nip
                ip = to_ipv4(ip)
                ipv4 = True
            except ValueError: