Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Possible bug in httplib

5 views
Skip to first unread message

Don Dwiggins

unread,
Feb 14, 2001, 2:19:44 PM2/14/01
to pytho...@python.org
I've been "doing exercises" with httplib to familiarize myself with it, and
I ran into a problem that I think might be a bug.

The HTTPConnection.request method takes an optional "body" argument, useful
for POST requests. When I tried to use it, the server I was talking to came
back with an empty reply. I was finally able to get the request accepted
using a sequence of putheader calls to send the Content-Type header as well
as Content-Length. I don't know whether Content-Type is required by the
HTTP spec, but at least one server calls for it.

Can anyone offer a more authoritative answer as to whether the request
method should be sending the Content-Type header?

Thanks,

--
Don Dwiggins
Advanced MP Technology
dw...@advancedmp.net


Dustin Boswell

unread,
Feb 15, 2001, 6:10:36 PM2/15/01
to
I'm not sure if it'll help your problem, but you should get fresh copies
of httplib.py and urllib.py (and any others). There are a bunch of
little bugs in the Python2.0 distribution.

Try the cvs repository....
http://cvs.sourceforge.net/cgi-bin/cvsweb.cgi/python/dist/src/?cvsroot=python

Hope that helps.

-Dustin Boswell ( bos...@caltech.edu )

0 new messages