there could be an exc

This commit is contained in:
JerryXiao 2021-01-18 14:59:57 +08:00
parent b43589a01e
commit 7c67531f48
Signed by: Jerry
GPG key ID: 9D9CE43650FF2BAA

View file

@ -252,11 +252,16 @@ def main() -> None:
elif args.action == 'status':
count = 0
failed = False
for entry in read_db():
if e := entry.get('error'):
print(e)
failed = True
break
for entry in read_db():
if report_dict := entry.get('report'):
count += 1
report = checkReport(**report_dict)
if count == 1:
if not failed and count == 1:
failed = report.failed
print(report.summary(verbose=args.verbose, show_package=True))
if count >= args.max and args.max > 0: