Handle decompression errors
This commit is contained in:
@@ -64,6 +64,9 @@ proc fetch*(url: Uri; oldApi=false): Future[JsonNode] {.async.} =
|
||||
echo "fetch error: ", result.getError
|
||||
release(token, true)
|
||||
raise rateLimitError()
|
||||
except ZippyError as e:
|
||||
echo "decompression error: ", e.msg, ", url: ", url
|
||||
raise newException(InternalError, "decompression failed: " & $url)
|
||||
except Exception as e:
|
||||
echo "error: ", e.msg, ", token: ", token[], ", url: ", url
|
||||
if "length" notin e.msg and "descriptor" notin e.msg:
|
||||
|
||||
Reference in New Issue
Block a user