Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(136)

Unified Diff: scripts/master/chromium_step.py

Issue 1812163002: Add log and link aliasing to BuildBot. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: Unused variable. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: scripts/master/chromium_step.py
diff --git a/scripts/master/chromium_step.py b/scripts/master/chromium_step.py
index 5f11771950e506b6a65d876a3909fbd47d2a8c40..7f449ee63427280a8c12113a1b649ed7913c9c12 100644
--- a/scripts/master/chromium_step.py
+++ b/scripts/master/chromium_step.py
@@ -505,6 +505,10 @@ class AnnotationObserver(buildstep.LogLineObserver):
@@@STEP_LINK@<label>@<url>@@@
Add a link with label <label> linking to <url> to the current stage.
+ If the label value is of the form "text-->base", this is considered an alias
+ link, and will add an alias named "text" with the value "url" to the log or
+ link named "base".
+
@@@STEP_STARTED@@@
Start the step at the cursor location.
@@ -1024,8 +1028,16 @@ class AnnotationObserver(buildstep.LogLineObserver):
os.chmod(graph_filename, EXECUTABLE_FILE_PERMISSIONS)
def addLinkToCursor(self, link_label, link_url):
- self.cursor['links'].append((link_label, link_url))
- self.cursor['step'].addURL(link_label, link_url)
+ parts = link_label.split('-->', 1)
+ link_alias = None
+ if len(parts) == 2:
+ link_alias, link_label = parts
+
+ self.cursor['links'].append((link_label, link_url, link_alias))
+ if not link_alias:
+ self.cursor['step'].addURL(link_label, link_url)
+ else:
+ self.cursor['step'].addAlias(link_label, link_url, text=link_alias)
def handleOutputLine(self, line):
"""This is called once with each line of the test log."""
« no previous file with comments | « masters/master.tryserver.chromium.perf/templates/build.html ('k') | scripts/master/unittests/annotator_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698