bodhi/masher.py | 5 ++++-
bodhi/tests/test_model.py | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 8bc40b239e5525dce21d60b528c250a306538738
Author: Luke Macken <lmacken(a)redhat.com>
Date: Fri Jan 22 09:26:21 2010 -0500
Minor test case tweak
diff --git a/bodhi/tests/test_model.py b/bodhi/tests/test_model.py
index f2c802f..c84fcaa 100644
--- a/bodhi/tests/test_model.py
+++ b/bodhi/tests/test_model.py
@@ -420,7 +420,7 @@ class TestPackageUpdate(testutil.DBTest):
up.status = 'testing'
up.status_comment()
assert len(up.comments) == 1
- assert up.comments[0].author == 'bodhi'
+ assert up.comments[0].author == 'bodhi', up.comments[0]
assert up.comments[0].text == 'This update has been pushed to testing'
up.status = 'stable'
up.status_comment()
commit 49a464593f20cb29ecc44251cc3d6e520548a7a4
Author: Luke Macken <lmacken(a)redhat.com>
Date: Fri Jan 22 09:25:55 2010 -0500
Support passing update titles instead of PackageUpdate instances to the MashTask
thread
diff --git a/bodhi/masher.py b/bodhi/masher.py
index 9b3edf0..97ccacb 100644
--- a/bodhi/masher.py
+++ b/bodhi/masher.py
@@ -167,6 +167,8 @@ class MashTask(Thread):
self.id = id
self.tag = None
self.updates = set()
+ if isinstance(updates[0], basestring):
+ updates = map(PackageUpdate.byTitle, updates)
map(self.updates.add, updates)
if self.updates:
up = self.updates.pop()
commit 40b27aff2202bcb0443a56a5f7ad2c11b37baa0c
Author: Luke Macken <lmacken(a)redhat.com>
Date: Fri Jan 22 09:25:37 2010 -0500
Only remove the masher thread if it exists
diff --git a/bodhi/masher.py b/bodhi/masher.py
index 6ae1ee6..9b3edf0 100644
--- a/bodhi/masher.py
+++ b/bodhi/masher.py
@@ -91,7 +91,8 @@ class Masher(object):
self.last_log = thread.log
mail.send_releng('Bodhi Masher Report %s' %
time.strftime("%y%m%d.%H%M"), thread.report())
- self._threads.remove(thread)
+ if thread in self._threads:
+ self._threads.remove(thread)
del thread
if len(self._threads) == 0:
if len(self._queue):
Show replies by date