mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-13 22:32:15 +00:00
Raise the correct exception on readtimeout errors, fixes #297
This commit is contained in:
@@ -103,7 +103,10 @@ class CachedDocumentManager(models.Manager):
|
||||
stat_update_count('eve_proxy_api_exception')
|
||||
raise DocumentRetrievalError(e.reason)
|
||||
else:
|
||||
doc.body = unicode(conn.read(), 'utf-8')
|
||||
try:
|
||||
doc.body = unicode(conn.read(), 'utf-8')
|
||||
except Exception, e:
|
||||
raise DocumentRetrievalError(e)
|
||||
doc.time_retrieved = now()
|
||||
|
||||
error = 0
|
||||
|
||||
Reference in New Issue
Block a user