mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52: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')
|
stat_update_count('eve_proxy_api_exception')
|
||||||
raise DocumentRetrievalError(e.reason)
|
raise DocumentRetrievalError(e.reason)
|
||||||
else:
|
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()
|
doc.time_retrieved = now()
|
||||||
|
|
||||||
error = 0
|
error = 0
|
||||||
|
|||||||
Reference in New Issue
Block a user