summaryrefslogtreecommitdiffstats
path: root/cnucnu/bugzilla_reporter.py
diff options
context:
space:
mode:
authorTill Maas <opensource@till.name>2010-12-25 12:41:56 +0100
committerTill Maas <opensource@till.name>2010-12-25 12:41:56 +0100
commit3b0f6b9f7ced2e69067c5d713d8f5fe59ead1251 (patch)
tree0cf21c9fdd46c29e673f5f6545b227a3b83db282 /cnucnu/bugzilla_reporter.py
parent259fd17580890468851c05f9ff646da24228f502 (diff)
downloadcnucnu-3b0f6b9f7ced2e69067c5d713d8f5fe59ead1251.tar.gz
cnucnu-3b0f6b9f7ced2e69067c5d713d8f5fe59ead1251.tar.xz
cnucnu-3b0f6b9f7ced2e69067c5d713d8f5fe59ead1251.zip
only change bug status if necessary
Diffstat (limited to 'cnucnu/bugzilla_reporter.py')
-rw-r--r--cnucnu/bugzilla_reporter.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/cnucnu/bugzilla_reporter.py b/cnucnu/bugzilla_reporter.py
index 428fedd..f7f799e 100644
--- a/cnucnu/bugzilla_reporter.py
+++ b/cnucnu/bugzilla_reporter.py
@@ -102,12 +102,11 @@ class BugzillaReporter(object):
bug_dict.update(self.new_bug)
if not dry_run:
new_bug = self.bz.createbug(**bug_dict)
- status = self.config['bug status']
change_status = None
print new_bug
- # TODO: check which status the newly created bug has
- if status != "ASSIGNED":
- change_status = self.bz._proxy.bugzilla.changeStatus(new_bug.bug_id, status, self.config['user'], "", "", False, False, 1)
+
+ if new_bug.bug_status != self.config['bug status']:
+ change_status = self.bz._proxy.bugzilla.changeStatus(new_bug.bug_id, self.config['bug status'], self.config['user'], "", "", False, False, 1)
print "status changed", change_status
return (new_bug, change_status)
else: