flake warnings (#304)

This commit is contained in:
Bruno Cabral
2022-12-12 02:44:27 -08:00
committed by GitHub
parent f10a3f1d1a
commit fb4109bd77
67 changed files with 252 additions and 248 deletions

View File

@@ -31,7 +31,7 @@ def should_sync(arch_config: dict, aur_supported: bool, handler: Optional[Proces
if handler:
handler.watcher.print(msg)
return False
except:
except Exception:
logger.warning("Could not convert the database synchronization time from '{}".format(SYNC_FILE))
traceback.print_exc()
return True
@@ -48,6 +48,6 @@ def register_sync(logger: Logger):
Path('/'.join(SYNC_FILE.split('/')[0:-1])).mkdir(parents=True, exist_ok=True)
with open(SYNC_FILE, 'w+') as f:
f.write(str(int(time.time())))
except:
except Exception:
logger.error("Could not write to database sync file '{}'".format(SYNC_FILE))
traceback.print_exc()