From patchwork Sun Oct 17 18:58:35 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lucas Meneghel Rodrigues X-Patchwork-Id: 260491 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o9HIwtth008804 for ; Sun, 17 Oct 2010 18:58:55 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932614Ab0JQS6i (ORCPT ); Sun, 17 Oct 2010 14:58:38 -0400 Received: from mx1.redhat.com ([209.132.183.28]:1872 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932591Ab0JQS6i (ORCPT ); Sun, 17 Oct 2010 14:58:38 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o9HIwbE0003918 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sun, 17 Oct 2010 14:58:37 -0400 Received: from autotest.virt.bos.redhat.com (autotest.virt.bos.redhat.com [10.16.72.47]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o9HIwa7I024720; Sun, 17 Oct 2010 14:58:37 -0400 From: Lucas Meneghel Rodrigues To: autotest@test.kernel.org Cc: kvm@vger.kernel.org, ehabkost@redhat.com, Lucas Meneghel Rodrigues Subject: Scheduler notification e-mail: Order failures by reason Date: Sun, 17 Oct 2010 14:58:35 -0400 Message-Id: <1287341915-854-1-git-send-email-lmr@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Sun, 17 Oct 2010 18:58:55 +0000 (UTC) diff --git a/scheduler/scheduler_models.py b/scheduler/scheduler_models.py index f94077a..c302dac 100644 --- a/scheduler/scheduler_models.py +++ b/scheduler/scheduler_models.py @@ -903,6 +903,7 @@ class Job(DBObject): WHERE t.job_idx = j.job_idx AND s.status_idx = t.status AND j.afe_job_id = %s + ORDER BY t.reason """ % self.id) failed_rows = [r for r in rows if not 'GOOD' in r]