httplib2 regressions?

12 views
Skip to first unread message

Sam Ruby

unread,
Sep 9, 2009, 1:43:48 PM9/9/09
to httplib2-dev
I updated Venus today to the latest httplib2[2], and now on two feeds
I'm getting errors:

From http://planet.intertwingly.net/planet.log :

>> 1252517351.650019 ERROR Error processing http://tomayko.com/feed
>> 1252517351.651100 ERROR error: Error -3 while decompressing data: incorrect header check
>> 1252517351.651241 ERROR File "/home/rubys/bzr/venus/planet/spider.py", line 316, in httpThread
>> (resp, content) = h.request(idna, 'GET', headers=headers)
>> 1252517351.651324 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 1071, in request
>> (response, new_content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey)
>> 1252517351.651405 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 887, in _request
>> (response, content) = self._conn_request(conn, request_uri, method, body, headers)
>> 1252517351.651485 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 873, in _conn_request
>> content = _decompressContent(response, content)
>> 1252517351.651564 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 351, in _decompressContent
>> content = zlib.decompress(content)

... and ...

>> 1252517381.088668 ERROR Error processing http://www.chrisjdavis.org/atom/1
>> 1252517381.095288 ERROR AttributeError: 'NoneType' object has no attribute 'makefile'
>> 1252517381.095453 ERROR File "/home/rubys/bzr/venus/planet/spider.py", line 316, in httpThread
>> (resp, content) = h.request(idna, 'GET', headers=headers)
>> 1252517381.095537 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 1101, in request
>> (response, content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey)
>> 1252517381.095619 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 887, in _request
>> (response, content) = self._conn_request(conn, request_uri, method, body, headers)
>> 1252517381.095699 ERROR File "/home/rubys/bzr/venus/planet/vendor/httplib2/__init__.py", line 859, in _conn_request
>> response = conn.getresponse()
>> 1252517381.095778 ERROR File "/usr/lib/python2.5/httplib.py", line 926, in getresponse
>> method=self._method)
>> 1252517381.095857 ERROR File "/usr/lib/python2.5/httplib.py", line 324, in __init__
>> self.fp = sock.makefile('rb', 0)

Any ideas?

- Sam Ruby

[1] http://intertwingly.net/blog/2009/09/09/Venus-Updates
[2] http://httplib2.googlecode.com/files/httplib2-0.5.0.tar.gz

Sam Ruby

unread,
Sep 9, 2009, 1:39:09 PM9/9/09
to httpli...@googlegroups.com

Joe Gregorio

unread,
Sep 9, 2009, 2:52:12 PM9/9/09
to httpli...@googlegroups.com
The second one is a known bug which has a patch attached, so I should get on applying that patch:


The second one looks like an exception raised from within zlib, in
that case httplib2 should probably retry the request but drop
the accept: gzip header. I think this issue was raised previously but 
I don't see a bug for it, can you log it as a bug?

   Thanks,
   -joe

Sam Ruby

unread,
Sep 9, 2009, 5:52:30 PM9/9/09
to httplib2-dev
On Sep 9, 2:52 pm, Joe Gregorio <j...@bitworking.org> wrote:
> The second one is a known bug which has a patch attached, so I should get on
> applying that patch:
>    http://code.google.com/p/httplib2/issues/detail?id=62

I've applied that patch locally, and it looks good.

> The second one looks like an exception raised from within zlib, in
> that case httplib2 should probably retry the request but drop
> the accept: gzip header. I think this issue was raised previously but
> I don't see a bug for it, can you log it as a bug?

http://code.google.com/p/httplib2/issues/detail?id=69

>    Thanks,
>    -joe

- Sam Ruby
Reply all
Reply to author
Forward
0 new messages