Time out after 30 seconds iwhen downloading

- Legacy-Id: 1903
This commit is contained in:
Pasi Eronen 2009-12-28 13:31:13 +00:00
parent 00eae6a19d
commit 1d8f81c0fb
3 changed files with 3 additions and 0 deletions

View file

@ -58,6 +58,7 @@ try:
log("url: "+URL)
log("downloading...")
socket.setdefaulttimeout(30)
response = urllib2.urlopen(URL)
#log("got \n"+str(response.info()))
log("parsing...")

View file

@ -199,6 +199,7 @@ if __name__ == '__main__':
log("url: "+QUEUE_URL)
log("downloading...")
socket.setdefaulttimeout(30)
response = urllib2.urlopen(QUEUE_URL)
(drafts, refs) = parse_all(response)

View file

@ -146,6 +146,7 @@ if __name__ == '__main__':
log("url: "+INDEX_URL)
log("downloading...")
socket.setdefaulttimeout(30)
response = urllib2.urlopen(INDEX_URL)
log("parsing...")
data = parse(response)