mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
8a885650f7
commit
0350e13e87
@ -87,11 +87,10 @@ def wayback_machine_cached_url(url, br=None, log=prints, timeout=60):
|
||||
q, 'wayback', parser=json.loads, limit=0.25, timeout=timeout)
|
||||
try:
|
||||
closest = data['archived_snapshots']['closest']
|
||||
except KeyError:
|
||||
pass
|
||||
else:
|
||||
if closest['available']:
|
||||
return closest['url']
|
||||
except Exception:
|
||||
pass
|
||||
from pprint import pformat
|
||||
log('Response from wayback machine:', pformat(data))
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user