[Patches] httplib.HTTP.connect raises wrong exception

Guido van Rossum guido@python.org
Mon, 27 Mar 2000 14:22:54 -0500


> In httplib.HTTP.connect a socket.error is raised when a non-numeric port is
> given.  Seems to me this is more correctly a ValueError.

Hmm...  It explicitly catches the ValueError and raises socket.error.
Why could it be doing this?  (Also, it does the same thing elsewhere
in the module.)

-0

--Guido van Rossum (home page: http://www.python.org/~guido/)