#2316 kojira: replace deprecated Thread.isAlive()
Merged 3 years ago by tkopecek. Opened 3 years ago by tkopecek.
tkopecek/koji issue2312  into  master

file modified
+3 -3
@@ -949,13 +949,13 @@ 

              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:

From py 2.7 exists an alias is_alive, so it is safe to replace it.

Fixes: https://pagure.io/koji/issue/2312

Metadata Update from @tkopecek:
- Pull-request tagged with: no_qe

3 years ago

Commit ac0e881 fixes this pull-request

Pull-Request has been merged by tkopecek

3 years ago