don't return blob timeout error from get_availability

This commit is contained in:
Jack Robison 2017-02-19 19:26:48 -05:00
parent e2f97ba0b4
commit d0b64ef255

View file

@ -2508,7 +2508,11 @@ class Daemon(AuthJSONRPCServer):
blob_hashes = [blob.blob_hash for blob in blobs]
if need_sd_blob:
# we don't want to use self._download_descriptor here because it would create a stream
sd_blob = yield self._download_blob(sd_hash, timeout=sd_timeout)
try:
sd_blob = yield self._download_blob(sd_hash, timeout=sd_timeout)
except Exception as err:
response = yield self._render_response(0.0)
defer.returnValue(response)
decoded = read_sd_blob(sd_blob)
blob_hashes = [blob.get("blob_hash") for blob in decoded['blobs']
if blob.get("blob_hash")]