This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eopadoan
Recipients eopadoan
Date 2007-09-11.17:26:24
SpamBayes Score 0.019862877
Marked as misclassified No
Message-id <1189531585.2.0.192204697498.issue1148@psf.upfronthosting.co.za>
In-reply-to
Content
To reproduce:

>>> import httplib
>>> conn = httplib.HTTPConnection("www.python.org")
>>> conn.request("GET", "/index.html")
>>> r1 = conn.getresponse()
>>> r1.read()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/eopadoan/pub/py3k/Lib/httplib.py", line 540, in read
    s = self._safe_read(self.length)
  File "/home/eopadoan/pub/py3k/Lib/httplib.py", line 627, in _safe_read
    return "".join(s)
TypeError: sequence item 0: expected string or Unicode, bytes found

Also, shouldn't the message  be like "...expected str, bytes found"?
History
Date User Action Args
2007-09-11 17:26:26eopadoansetspambayes_score: 0.0198629 -> 0.019862877
recipients: + eopadoan
2007-09-11 17:26:25eopadoansetspambayes_score: 0.0198629 -> 0.0198629
messageid: <1189531585.2.0.192204697498.issue1148@psf.upfronthosting.co.za>
2007-09-11 17:26:24eopadoanlinkissue1148 messages
2007-09-11 17:26:24eopadoancreate