Bugs item #1282647, was opened at 2005-09-06 10:16 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1282647&group_id=5470
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Extension Modules Group: Platform-specific Status: Open Resolution: None Priority: 5 Submitted By: Ganesan Rajagopal (rganesan) Assigned to: Nobody/Anonymous (nobody) Summary: socket.getaddrinfo() bug for IPv6 enabled platforms Initial Comment: ====== getaddrinfo(host, port[, family[, socktype[, proto[, flags]]]]) Resolves the host/port argument, into a sequence of 5-tuples that contain all the necessary argument for the sockets manipulation. host is a domain name, a string representation of IPv4/v6 address or None. port is a string service name (like 'http'), a numeric port number or None. ====== On Linux (and FreeBSD and probably other IPv6 enabled hosts), port as a number raises a socket exception ====== $ python2.4 Python 2.4.1 (#2, May 5 2005, 11:32:06) [GCC 3.3.5 (Debian 1:3.3.5-12)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import socket >>> socket.getaddrinfo('6bone.net', 'http') [(10, 1, 6, '', ('2001:5c0:0:2::24', 80, 0, 0)), (2, 1, 6, '', ('209.71.226.24', 80))] >>> socket.getaddrinfo('6bone.net', 80) Traceback (most recent call last): File "<stdin>", line 1, in ? socket.gaierror: (-8, 'Servname not supported for ai_socktype') ====== Since, on Windows 2003 Server (no IPv6) and Solaris 2.8 (no IPv6), the call works correctly, I am filing this bug as platform specific. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1282647&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com