[Python-Dev] Failure on assorted buildbots - Address already in use
Nick Coghlan
ncoghlan at gmail.com
Wed Jul 25 15:30:43 CEST 2007
Andrew Bennetts wrote:
> Facundo Batista wrote:
>> 2007/7/24, Nick Coghlan <ncoghlan at gmail.com>:
>> Maybe the tests should be changed to use a not-so-standard port.
>
> Or use port 0 to let the operating system pick a free port:
>
> >>> import socket
> >>> s = socket.socket()
> >>> s.bind(("127.0.0.1", 0))
> >>> s.getsockname()
> ('127.0.0.1', 42669)
>
> -Andrew.
I've changed test_urllib2_localnet to work this way - we'll see if it
improves matters.
Cheers,
Nick.
--
Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
---------------------------------------------------------------
http://www.boredomandlaziness.org
More information about the Python-Dev
mailing list