From patchwork Mon Nov 26 17:19:12 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antonio Terceiro X-Patchwork-Id: 13220 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 560444C178E for ; Mon, 26 Nov 2012 17:19:15 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id E1F57A18274 for ; Mon, 26 Nov 2012 17:19:14 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id c10so4997993ieb.11 for ; Mon, 26 Nov 2012 09:19:14 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf :content-type:mime-version:x-launchpad-project:x-launchpad-branch :x-launchpad-message-rationale:x-launchpad-branch-revision-number :x-launchpad-notification-type:to:from:subject:message-id:date :reply-to:sender:errors-to:precedence:x-generated-by :x-launchpad-hash:x-gm-message-state; bh=SQw+uKu7gBEsm0eMMtB8OTwaGFn5SJGUBcToJWOD8xY=; b=Xl3t5chWRKPPlue+Zwfx266uBmA9OM7ts1c0CgiCX8iP9lQP56T4e2x9ZBwU+iFWmM GpYAqQJDlJ+9J9YuQe5HwIC2U/rb30wR0F/9JREf+tmphPj+hMM0pXioIv8SWZLLHKvx qpXBKLMpbYC478GFNnKizpWdqWevJmHbMor7/z47SNoJLmz6tcIDJ2WkfLLNeyeMU0LH Wzo2bToSwMFBgNXoxjNuTdRUgMsCpwJatNfGBqvH1edbhKecZW16MOHPT9qyXB+1je1d latgxDlPqlMtqQwA9zxb7NIqh61D0/dioo50uqFsZcGOpUH78rn861ifQbehYCRYe2Zn FFuw== Received: by 10.50.161.169 with SMTP id xt9mr14708629igb.62.1353950354374; Mon, 26 Nov 2012 09:19:14 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.67.148 with SMTP id n20csp304158igt; Mon, 26 Nov 2012 09:19:13 -0800 (PST) Received: by 10.216.70.138 with SMTP id p10mr5085122wed.47.1353950353154; Mon, 26 Nov 2012 09:19:13 -0800 (PST) Received: from indium.canonical.com (indium.canonical.com. [91.189.90.7]) by mx.google.com with ESMTPS id k47si4960572wej.39.2012.11.26.09.19.12 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 26 Nov 2012 09:19:13 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) client-ip=91.189.90.7; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) smtp.mail=bounces@canonical.com Received: from ackee.canonical.com ([91.189.89.26]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1Td2Ku-00062w-Ho for ; Mon, 26 Nov 2012 17:19:12 +0000 Received: from ackee.canonical.com (localhost [127.0.0.1]) by ackee.canonical.com (Postfix) with ESMTP id 7553CE0406 for ; Mon, 26 Nov 2012 17:19:12 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: lava-dispatcher X-Launchpad-Branch: ~linaro-validation/lava-dispatcher/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 467 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-validation/lava-dispatcher/trunk] Rev 467: initialize variable to avoid exceptions when handling a KeyboardInterrupt (i.e. ctrl-C) Message-Id: <20121126171912.16081.45598.launchpad@ackee.canonical.com> Date: Mon, 26 Nov 2012 17:19:12 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="16309"; Instance="launchpad-lazr.conf" X-Launchpad-Hash: afcdb5c7761fbf3bf0c8627a6a9358b76d3d3b1f X-Gm-Message-State: ALoCoQnjWen0C67QyvgR2ObxtJ4CoNO2VRIqv4gFS7LjKiD9DLiXuBg4bvt8wtd4yWhMHbSY/IEt Merge authors: Antonio Terceiro (terceiro) Related merge proposals: https://code.launchpad.net/~terceiro/lava-dispatcher/avoid-unbound-local-error-after-ctrl-c/+merge/136025 proposed by: Antonio Terceiro (terceiro) review: Approve - Andy Doan (doanac) ------------------------------------------------------------ revno: 467 [merge] fixes bug: https://launchpad.net/bugs/1079318 committer: Antonio Terceiro branch nick: lava-dispatcher timestamp: Mon 2012-11-26 14:18:05 -0300 message: initialize variable to avoid exceptions when handling a KeyboardInterrupt (i.e. ctrl-C) modified: lava_dispatcher/job.py --- lp:lava-dispatcher https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk You are subscribed to branch lp:lava-dispatcher. To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk/+edit-subscription === modified file 'lava_dispatcher/job.py' --- lava_dispatcher/job.py 2012-11-22 03:19:02 +0000 +++ lava_dispatcher/job.py 2012-11-24 20:58:07 +0000 @@ -172,6 +172,7 @@ metadata = cmd.get('metadata', {}) self.context.test_data.add_metadata(metadata) action = lava_commands[cmd['command']](self.context) + err = None try: status = 'fail' action.run(**params)