oeqa/commands: Fix compatibility with python 3.9

Submitted by Richard Purdie on Nov. 21, 2020, 10:50 a.m. | Patch ID: 178199

Details

Message ID 20201121105043.1208940-1-richard.purdie@linuxfoundation.org
State New
Headers show

Commit Message

Richard Purdie Nov. 21, 2020, 10:50 a.m.
Python 3.9 dropped isAlive() so use the preferred is_alive().

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>

---
 meta/lib/oeqa/utils/commands.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.25.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#144899): https://lists.openembedded.org/g/openembedded-core/message/144899
Mute This Topic: https://lists.openembedded.org/mt/78409067/1003190
Group Owner: openembedded-core+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [mhalstead@linuxfoundation.org]
-=-=-=-=-=-=-=-=-=-=-=-

Patch hide | download patch | download mbox

diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py
index 8059cbce3e1..6c1535ddfbf 100644
--- a/meta/lib/oeqa/utils/commands.py
+++ b/meta/lib/oeqa/utils/commands.py
@@ -125,11 +125,11 @@  class Command(object):
 
     def stop(self):
         for thread in self.threads:
-            if thread.isAlive():
+            if thread.is_alive():
                 self.process.terminate()
             # let's give it more time to terminate gracefully before killing it
             thread.join(5)
-            if thread.isAlive():
+            if thread.is_alive():
                 self.process.kill()
                 thread.join()