From 0fc190dc9980e5f5c883cae358804e97eb280506 Mon Sep 17 00:00:00 2001 From: cpettet Date: Mon, 10 Nov 2014 09:20:26 -0600 Subject: fixes T881 --- bugzilla_create.py | 2 +- wmfphablib/bzlib.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/bugzilla_create.py b/bugzilla_create.py index 13fe05b..873637f 100755 --- a/bugzilla_create.py +++ b/bugzilla_create.py @@ -235,7 +235,7 @@ def create(bugid): ccphids.append(mailinglist_phid(assignee)) vlog("Ticket Info: %s" % (desc_block,)) - ticket = phab.maniphest.createtask(title=buginfo['summary'], + ticket = phab.maniphest.createtask(title=buginfo['summary'], description=full_description, projectPHIDs=phids, ccPHIDs=ccphids, diff --git a/wmfphablib/bzlib.py b/wmfphablib/bzlib.py index 62e70e3..8b7f733 100755 --- a/wmfphablib/bzlib.py +++ b/wmfphablib/bzlib.py @@ -22,6 +22,9 @@ def build_comment(c): """ takes a native bz comment dict and outputs a dict ready for processing into phab """ + + dupe_literals = ['This bug has been marked as a duplicate of bug', + 'has been marked as a duplicate of this bug'] clean_c = {} clean_c['author'] = c['author'].split('@')[0] clean_c['creation_time'] = str(c['creation_time']) @@ -45,7 +48,7 @@ def build_comment(c): for t in text: if t.startswith('Created attachment'): continue - elif t.startswith('***'): + elif '***' in t and any(map(lambda l: l in t, dupe_literals)): fmt_text.append('%%%{0}%%%'.format(t)) else: fmt_text.append(t) -- cgit v1.2.3