httplib.IncompleteRead: IncompleteRead received from launchpad
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
launchpadlib |
Fix Released
|
High
|
Unassigned |
Bug Description
I've been getting this intermittently from launchpad:
Date: Tue, 23 Mar 2010 09:32:13 -0700
From: Cron Daemon <email address hidden>
To: <email address hidden>
Subject: Cron <bryce@chideok> /home/bryce/
Traceback (most recent call last):
File "/home/
if len(list(tasks)) == 0:
File "/usr/lib/
unicode(
File "/usr/lib/
response, content = self._request(url, extra_headers=
File "/usr/lib/
str(url), method=method, body=data, headers=headers)
File "/usr/lib/
(response, new_content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey)
File "/usr/lib/
redirections, cachekey)
File "/usr/lib/
(response, content) = self._conn_
File "/usr/lib/
conn, request_uri, method, body, headers)
File "/usr/lib/
content = response.read()
File "/usr/lib/
s = self._safe_
File "/usr/lib/
raise IncompleteRead(
httplib.
This particular error involved this chunk of code:
tags = tag_set[
tasks = s.searchTasks(tags = tags, tags_combinator = "All")
if len(list(tasks)) == 0:
# If there are no bug_tasks, don't bother recording them
So I'm not really doing anything except firing a query and getting a count of the results. (If there is a more bandwidth-friendly way of doing this, I'd love to know.)
What is this IncompleteRead exception? I assume it's just some issue internally in launchpad that can't be avoided from my end, except for exception handling. Should I just immediately retry when hitting this error? Or sleep for some period?
But I really hate having to lace my code with catches to handle all the various types of exceptions launchpad emits. Is there something that can be done within the launchpadapi code to handle these exceptions more gracefully for me?
Some other times I hit this particular exception recently with this and another script:
Date: Fri, 19 Mar 2010 16:08:14 -0700
Date: Fri, 19 Mar 2010 17:01:14 -0700
Date: Sun, 21 Mar 2010 16:36:22 -0700
Date: Mon, 22 Mar 2010 12:45:55 -0700
Date: Mon, 22 Mar 2010 14:01:17 -0700
Date: Mon, 22 Mar 2010 16:02:47 -0700
Date: Mon, 22 Mar 2010 17:02:54 -0700
Date: Mon, 22 Mar 2010 18:02:47 -0700
Date: Mon, 22 Mar 2010 18:05:50 -0700
Date: Tue, 23 Mar 2010 09:32:13 -0700
affects: | launchpad → launchpad-foundations |
Changed in launchpad-foundations: | |
status: | New → Triaged |
importance: | Undecided → High |
milestone: | none → 10.04 |
Changed in launchpad: | |
status: | New → Triaged |
affects: | launchpad → launchpadlib |
Changed in launchpadlib: | |
milestone: | 10.04 → none |
status: | Triaged → Fix Released |
It means the http response said 'x bytes' but the script only read 'y' bytes before the connection was interrupted. A network issue on your end could easily cause this.
Does it still happen?