mirror of
https://github.com/vikstrous/pirate-get
synced 2025-01-10 10:04:21 +01:00
show the reason in case of the mirror failure
This commit is contained in:
parent
6642130fc5
commit
095f2d2b38
@ -259,8 +259,9 @@ def connect_mirror(mirror, printer, args):
|
|||||||
mode=args.action,
|
mode=args.action,
|
||||||
terms=args.search,
|
terms=args.search,
|
||||||
mirror=mirror)
|
mirror=mirror)
|
||||||
except (urllib.error.URLError, socket.timeout, IOError, ValueError):
|
except (urllib.error.URLError, socket.timeout, IOError, ValueError) as e:
|
||||||
printer.print('Failed', color='WARN')
|
printer.print('Failed', color='WARN', end=' ')
|
||||||
|
printer.print('(', e, ')', sep='')
|
||||||
return None
|
return None
|
||||||
else:
|
else:
|
||||||
printer.print('Ok', color='alt')
|
printer.print('Ok', color='alt')
|
||||||
|
Loading…
Reference in New Issue
Block a user