Bug 1384759 - Only filter test tasks for Servo changes; r=froydnj
authorGregory Szorc <gps@mozilla.com>
Wed, 26 Jul 2017 17:09:53 -0700
changeset 422605 13358d0eb5a1e9651d7549d9d00e34b233c47ba2
parent 422604 6504499c1689d9199c355e07164b849f9144ca2f
child 422606 951aac3f7728936077ced35aec833aee11254bdd
push id1517
push userjlorenzo@mozilla.com
push dateThu, 14 Sep 2017 16:50:54 +0000
treeherdermozilla-release@3b41fd564418 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1384759
milestone56.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1384759 - Only filter test tasks for Servo changes; r=froydnj Previously, Servo-initiated CI only ran tasks if they were on the Linux64 platform. Now that we compile Servo code into Firefox (Stylo), we need to verify that Firefox at least builds on other platforms when Servo code changes. This commit tweaks our task filtering logic to only screen "test" tasks. This enables builds and other task kinds for Servo changes. The solution isn't perfect. One can make a case that deleting the filter completely is appropriate. But until we have more Servo code used by Firefox, I'm inclined to keep the optimization so it lessens CI load. MozReview-Commit-ID: 1QMrK27439C
taskcluster/taskgraph/filter_tasks.py
--- a/taskcluster/taskgraph/filter_tasks.py
+++ b/taskcluster/taskgraph/filter_tasks.py
@@ -32,23 +32,36 @@ def filter_target_tasks(graph, parameter
 
     attr = parameters.get('target_tasks_method', 'all_tasks')
     fn = target_tasks.get_method(attr)
     return fn(graph, parameters)
 
 
 @filter_task('check_servo')
 def filter_servo(graph, parameters):
-    """bug 1339542 When Servo vcs sync service lands Servo commits in
-    autoland repo, run linux64-stylo tests but skip other
-    platforms (to  reduce test load)."""
+    """Filter out tasks for Servo vendoring changesets.
+
+    If the change triggering is related to Servo vendoring, impact is minimal
+    because not all platforms use Servo code.
 
-    SERVO_PLATFORMS = {
+    We filter out tests on platforms that don't run Servo tests because running
+    tests will accomplish little for these changes.
+    """
+
+    SERVO_TEST_PLATFORMS = {
         'linux64',
         'linux64-stylo',
     }
 
     def fltr(task):
         if parameters.get('owner') != "servo-vcs-sync@mozilla.com":
             return True
-        return task.attributes.get('build_platform') in SERVO_PLATFORMS
+
+        # This is a Servo vendor change.
+
+        # Servo code is compiled. So we at least need to build. Resource
+        # savings come from pruning tests. So that's where we filter.
+        if task.attributes.get('kind') != 'test':
+            return True
+
+        return task.attributes.get('build_platform') in SERVO_TEST_PLATFORMS
 
     return [l for l, t in graph.tasks.iteritems() if fltr(t)]