From: Kyr Shatskyy Date: Thu, 14 Nov 2019 19:06:42 +0000 (+0100) Subject: suite: get rid of cmp for py3 X-Git-Tag: 1.1.0~194^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F1355%2Fhead;p=teuthology.git suite: get rid of cmp for py3 Signed-off-by: Kyr Shatskyy --- diff --git a/teuthology/suite/__init__.py b/teuthology/suite/__init__.py index a7060d2e..910812ab 100644 --- a/teuthology/suite/__init__.py +++ b/teuthology/suite/__init__.py @@ -223,7 +223,7 @@ def wait(name, max_job_time, upload_url): jobs = reporter.get_jobs(name, fields=['job_id', 'status', 'description', 'log_href']) # dead, fail, pass : show fail/dead jobs first - jobs = sorted(jobs, lambda a, b: cmp(a['status'], b['status'])) + jobs = sorted(jobs, key=lambda x: x['status']) for job in jobs: if upload_url: url = os.path.join(upload_url, name, job['job_id'])