Bug 1072163 - Remove links to TBPL from Try server emails
--- a/bin/try_mailer.py
+++ b/bin/try_mailer.py
@@ -62,19 +62,17 @@ def makeTryMessage(build, log_url):
who = props['who']
else:
users = build.getResponsibleUsers()
if users:
who = users[0]
else:
raise ValueError("I don't know who did this build")
- branch = props['branch']
- tree = 'try-comm-central' if 'comm' in branch else 'try'
- tbpl_tree = 'Thunderbird-Try' if 'comm' in branch else 'Try'
+ tree = props['branch']
if 'got_revision' in props:
revision = props['got_revision'][:12]
elif 'revision' in props:
revision = props['revision'][:12]
else:
revision = 'unknown'
@@ -120,22 +118,22 @@ Your %(tree)s Server %(task)s (%(revisio
summary = summary.replace('<br>', '')
summary = re.sub("\n\n*", "\n", summary)
text += '%s\n\n' % summary
if log_url:
log_url = log_url.replace('://stage', '://ftp')
text += "The full log for this %(task)s run is available at <a href=\"%(log_url)s\">%(log_url)s</a>.\n\n" % locals()
- text += "For an overview of all results see <a href=\"https://treeherder.mozilla.org/#/jobs?repo=%(tree)s&revision=%(revision)s\">Treeherder</a>.\n" % locals()
- text += "Alternatively, view them on <a href=\"https://tbpl.mozilla.org/?tree=%(tbpl_tree)s&rev=%(revision)s\">TBPL</a> (soon to be deprecated).\n" % locals()
+ treeherder_url = "https://treeherder.mozilla.org/#/jobs?repo=%(tree)s&revision=%(revision)s" % locals()
+ text += "For an overview of all results see <a href=\"%(treeherder_url)\">Treeherder</a>.\n" % locals()
text = re.sub("\n", "<br>\n", text)
- headers = {"In-Reply-To": "<%(branch)s-%(revision)s>" % locals(),
- "References": "<%(branch)s-%(revision)s>" % locals(),
+ headers = {"In-Reply-To": "<%(tree)s-%(revision)s>" % locals(),
+ "References": "<%(tree)s-%(revision)s>" % locals(),
}
return dict(
subject=subject,
body=text,
headers=headers,
author=who,
type='html',
--- a/status/generators.py
+++ b/status/generators.py
@@ -1,32 +1,27 @@
import re
def buildTryChangeMessage(change, packageDir):
got_revision = revision = change.revision[:12]
who = change.who
- branch = change.branch
- tree = 'try-comm-central' if 'comm' in branch else 'try'
- tbpl_tree = 'Thunderbird-Try' if 'comm' in branch else 'Try'
+ tree = change.branch
packageDir = packageDir % locals()
msgdict = {"type": "plain"}
msgdict['subject'] = "%(tree)s submission %(revision)s" % locals()
- msgdict['headers'] = {"In-Reply-To": "<%(branch)s-%(revision)s>" % locals(),
- "References": "<%(branch)s-%(revision)s>" % locals(),
+ msgdict['headers'] = {"In-Reply-To": "<%(tree)s-%(revision)s>" % locals(),
+ "References": "<%(tree)s-%(revision)s>" % locals(),
}
msgdict["body"] = """\
Thank you for your try submission. It's the best!
Results will be displayed on Treeherder as they come in:
https://treeherder.mozilla.org/#/jobs?repo=%(tree)s&revision=%(revision)s
-Alternatively, view them on TBPL (soon to be deprecated):
-https://tbpl.mozilla.org/?tree=%(tbpl_tree)s&rev=%(revision)s
-
Once completed, builds and logs will be available at:
%(packageDir)s
""" % locals()
commitTitles = change.properties.getProperty('commit_titles')
if commitTitles:
title = getSensibleCommitTitle(commitTitles)
allTitles = '\n * '.join(commitTitles)