From df3666c9bf07c06bb8ebe59a7dd89f027f09bbb5 Mon Sep 17 00:00:00 2001 From: Tomas Kopecek Date: Jun 16 2020 10:06:53 +0000 Subject: kojira: replace deprecated Thread.isAlive() From py 2.7 exists an alias is_alive, so it is safe to replace it. Fixes: https://pagure.io/koji/issue/2312 --- diff --git a/util/kojira b/util/kojira index dd13f13..3ad4d4b 100755 --- a/util/kojira +++ b/util/kojira @@ -949,13 +949,13 @@ def main(options, session): repomgr.checkQueue() repomgr.printState() repomgr.pruneLocalRepos() - if not curr_chk_thread.isAlive(): + if not curr_chk_thread.is_alive(): logger.error("Currency checker thread died. Restarting it.") curr_chk_thread = start_currency_checker(session, repomgr) - if options.check_external_repos and not curr_ext_chk_thread.isAlive(): + if options.check_external_repos and not curr_ext_chk_thread.is_alive(): logger.error("External currency checker thread died. Restarting it.") curr_ext_chk_thread = start_external_currency_checker(session, repomgr) - if not regen_thread.isAlive(): + if not regen_thread.is_alive(): logger.error("Regeneration thread died. Restarting it.") regen_thread = start_regen_loop(session, repomgr) except KeyboardInterrupt: