Bug 1641403 - Follow-up: Create target_task_method for Thunderbird Searchfox indexing. r=darktrojan DONTBUILD
The actual searchfox_index method includes tasks that do not exist in the
Thunderbird taskgraph. Register a new method specific to Thunderbird that
includes only what is needed.
Differential Revision:
https://phabricator.services.mozilla.com/D81261
--- a/.cron.yml
+++ b/.cron.yml
@@ -55,13 +55,13 @@ jobs:
run-on-projects:
- comm-central
when: [] # never (hook only)
- name: searchfox-index
job:
type: decision-task
treeherder-symbol: Searchfox
- target-tasks-method: searchfox_index
+ target-tasks-method: comm_searchfox_index
run-on-projects:
- comm-central
when:
- {hour: 11, minute: 0}
--- a/taskcluster/comm_taskgraph/__init__.py
+++ b/taskcluster/comm_taskgraph/__init__.py
@@ -20,17 +20,17 @@ BALROG_PRODUCT = 'Thunderbird'
def register(graph_config):
"""
Import all modules that are siblings of this one, triggering decorators in
the process.
"""
logger.info("{} path registered".format(__name__))
- _import_modules(['documentation', 'actions', 'transforms.job.toolchain'])
+ _import_modules(['documentation', 'actions', 'target_tasks', 'transforms.job.toolchain'])
def _import_modules(modules):
for module in modules:
import_module(".{}".format(module), package=__name__)
def get_decision_parameters(graph_config, parameters):
new file mode 100644
--- /dev/null
+++ b/taskcluster/comm_taskgraph/target_tasks.py
@@ -0,0 +1,16 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+from __future__ import absolute_import, print_function, unicode_literals
+
+from taskgraph.target_tasks import _target_task
+
+
+@_target_task('comm_searchfox_index')
+def target_tasks_searchfox(full_task_graph, parameters, graph_config):
+ """Select tasks required for indexing Thunderbird for Searchfox web site each day"""
+ return ['searchfox-linux64-searchfox/debug',
+ 'searchfox-macosx64-searchfox/debug',
+ 'searchfox-win64-searchfox/debug',
+ ]