classification
Title: Socket Documentation Error
Type: Stage:
Components: Documentation Versions: Python 2.7
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: docs@python Nosy List:
Priority: normal Keywords:

Created on 2013-01-09 21:04 by sghose, last changed 2013-01-09 21:43 by benjamin.peterson. This issue is now closed.

Messages (2)
msg179487 - (view) Author: Ronnie Ghose (sghose) Date: 2013-01-09 21:04
Running the example given in the docs gives the following:


In [8]: socket.getaddrinfo('www.python.org',80)
Out[8]:
[(2, 1, 6, '', ('82.94.164.162', 80)),
 (2, 2, 17, '', ('82.94.164.162', 80)),
 (2, 3, 0, '', ('82.94.164.162', 80)),
 (10, 1, 6, '', ('2001:888:2000:d::a2', 80, 0, 0)),
 (10, 2, 17, '', ('2001:888:2000:d::a2', 80, 0, 0)),
 (10, 3, 0, '', ('2001:888:2000:d::a2', 80, 0, 0))]

In [9]: socket.getaddrinfo('www.python.org',80,socket.SOL_TCP)
---------------------------------------------------------------------------
gaierror                                  Traceback (most recent call last)
/home/sghose/ADAPT/dns/<ipython-input-9-faa58a2f7926> in <module>()
----> 1 socket.getaddrinfo('www.python.org',80,socket.SOL_TCP)

gaierror: [Errno -6] ai_family not supported
msg179488 - (view) Author: Ronnie Ghose (sghose) Date: 2013-01-09 21:11
sorry  - my error. accidentally omitted somethings
History
Date User Action Args
2013-01-09 21:43:15benjamin.petersonsetresolution: not a bug
2013-01-09 21:12:06sghosesetnosy: - docs@python, sghose
2013-01-09 21:11:59sghosesetmessages: + msg179488
2013-01-09 21:11:43sghosesetstatus: open -> closed
2013-01-09 21:04:26sghosecreate