classification
Title: Exception for test_urllib2_localnet
Type: behavior Stage: resolved
Components: Tests Versions: Python 2.5
process
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: Nosy List: episodeiv, jimhermann, r.david.murray
Priority: low Keywords:

Created on 2008-08-17 23:34 by jimhermann, last changed 2009-04-21 02:14 by r.david.murray. This issue is now closed.

Messages (3)
msg71300 - (view) Author: Jim Hermann (jimhermann) Date: 2008-08-17 23:34
When I installed Python 2.5.2 on my Fedora Core 4 system, I ran 'make
test" and the process stopped at this point:

test_urllib2_localnet
Exception in thread Thread-1067:
Traceback (most recent call last):
  File "/usr/local/src/Python-2.5.2/Lib/threading.py", line 486, in
__bootstrap_inner
    self.run()
  File "/usr/local/src/Python-2.5.2/Lib/test/test_urllib2_localnet.py",
line 64, in run
    self._RequestHandlerClass)
  File "/usr/local/src/Python-2.5.2/Lib/test/test_urllib2_localnet.py",
line 22, in __init__
    RequestHandlerClass)
  File "/usr/local/src/Python-2.5.2/Lib/SocketServer.py", line 330, in
__init__
    self.server_bind()
  File "/usr/local/src/Python-2.5.2/Lib/BaseHTTPServer.py", line 101, in
server_bind
    SocketServer.TCPServer.server_bind(self)
  File "/usr/local/src/Python-2.5.2/Lib/SocketServer.py", line 341, in
server_bind
    self.socket.bind(self.server_address)
  File "<string>", line 1, in bind
error: (98, 'Address already in use')

Thanks.

Jim
msg86190 - (view) Author: Dennis Lichtenthäler (episodeiv) Date: 2009-04-20 07:52
I get the same behavior on an up-to-date Gentoo machine with Python
2.5.4. It seems, test_urllib2_localnet tries to bind to port 8080. If
something else is listening there, I get this error.
I changed the test to point to a different port and things seem to work.

Perhaps the test should check whether the port is available before
binding to it or even use a random port... 8080 is all too common!
msg86216 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2009-04-21 02:14
test_urllib2_localnet works for me if something is running on port 8080
on python 2.6.  Since python 2.5 is in security-fix-only mode, this bug
report is out of date.
History
Date User Action Args
2009-04-21 02:14:18r.david.murraysetstatus: open -> closed
priority: low
type: crash -> behavior


nosy: + r.david.murray
messages: + msg86216
resolution: out of date
stage: resolved
2009-04-20 07:52:53episodeivsetnosy: + episodeiv
messages: + msg86190
2008-08-17 23:34:28jimhermanncreate