diff mbox

[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
State Accepted
Headers show

Commit Message

Antonio Terceiro Nov. 26, 2012, 5:19 p.m. UTC
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 <antonio.terceiro@linaro.org>
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
diff mbox

Patch

=== 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)