Skip to content
Snippets Groups Projects
Commit 0f42e5a4 authored by Julien Cristau's avatar Julien Cristau Committed by Johan Lorenzo
Browse files

taskcluster: bump taskgraph to 3.2.0

In addition to the requirements bump itself, this means:
- bump decision-mobile docker image
- rename job-defaults to task-defaults, jobs to tasks, job-template to task-template
- stop setting parameters that are now handled by taskgraph upstream
parent d5b43817
No related branches found
No related tags found
No related merge requests found
Showing
with 54 additions and 42 deletions
......@@ -260,7 +260,7 @@ tasks:
# Note: This task is built server side without the context or tooling that
# exist in tree so we must hard code the hash
image:
mozillareleases/taskgraph:decision-mobile-625975b642c148be4c6f1d8ee5cedf7399f5d0dd33d275ff69d5934e3082d4a9@sha256:bfb26700182486e1c6c52701baea6f386fa39e5e25417423c27845933605ad43
mozillareleases/taskgraph:decision-mobile-3c208673efd0df8ff6aa174916582a851b5a3e7f40e07f0a446902cca5ed838f@sha256:68fcb0e64e736eb883e5ae61347a45f59eeb78875a09aa56cbf0fe73dfdfdeeb
maxRunTime: 1800
......
......@@ -16,7 +16,6 @@ from .build_config import get_components, get_version
extend_parameters_schema({
Required("pull_request_number"): Any(All(int, Range(min=1)), None),
Required("next_version"): Any(str, None),
Required("version"): str,
})
def register(graph_config):
......@@ -36,6 +35,4 @@ def get_decision_parameters(graph_config, parameters):
# Environment is defined in .taskcluster.yml
pr_number = os.environ.get("MOBILE_PULL_REQUEST_NUMBER", None)
parameters["pull_request_number"] = None if pr_number is None else int(pr_number)
version = get_version()
parameters["version"] = version
parameters.setdefault("next_version", None)
......@@ -22,21 +22,21 @@ schema = Schema({
def loader(kind, path, config, params, loaded_tasks):
"""
Load tasks based on the jobs dependant kind, designed to attach all dependencies of a single
Load tasks based on the tasks dependent kind, designed to attach all dependencies of a single
kind to the loaded task.
Required ``group-by-fn`` is used to define how we coalesce the
multiple deps together to pass to transforms, e.g. all kinds specified get
collapsed by platform with `build-type`
Optional ``job-template`` kind configuration value, if specified, will be used to
Optional ``task-template`` kind configuration value, if specified, will be used to
pass configuration down to the specified transforms used.
"""
job_template = config.get('job-template')
task_template = config.get('task-template')
for dep_tasks in group_tasks(config, loaded_tasks):
job = {'dependent-tasks': {dep.label: dep for dep in dep_tasks}}
if job_template:
job.update(copy.deepcopy(job_template))
task = {'dependent-tasks': {dep.label: dep for dep in dep_tasks}}
if task_template:
task.update(copy.deepcopy(task_template))
yield job
yield task
......@@ -26,7 +26,7 @@ schema = Schema({
def loader(kind, path, config, params, loaded_tasks):
"""
Load tasks based on the jobs dependant kinds, designed for use as
Load tasks based on the tasks dependent kinds, designed for use as
multiple-dependent needs.
Required ``group-by-fn`` is used to define how we coalesce the
......@@ -37,12 +37,12 @@ def loader(kind, path, config, params, loaded_tasks):
which upstream kind to inherit attrs from. See ``get_primary_dep``.
The `only-for-build-type` kind configuration, if specified, will limit
the build types for which a job will be created.
the build types for which a task will be created.
Optional ``job-template`` kind configuration value, if specified, will be used to
Optional ``task-template`` kind configuration value, if specified, will be used to
pass configuration down to the specified transforms used.
"""
job_template = config.get('job-template')
task_template = config.get('task-template')
for dep_tasks in group_tasks(config, loaded_tasks):
kinds = [dep.kind for dep in dep_tasks]
......@@ -52,12 +52,12 @@ def loader(kind, path, config, params, loaded_tasks):
dep_tasks_per_kind = {dep.kind: dep for dep in dep_tasks}
job = {'dependent-tasks': dep_tasks_per_kind}
job['primary-dependency'] = get_primary_dep(config, dep_tasks_per_kind)
if job_template:
job.update(copy.deepcopy(job_template))
task = {'dependent-tasks': dep_tasks_per_kind}
task['primary-dependency'] = get_primary_dep(config, dep_tasks_per_kind)
if task_template:
task.update(copy.deepcopy(task_template))
yield job
yield task
def assert_unique_members(kinds, error_msg=None):
......
......@@ -19,9 +19,9 @@ def build_treeherder_definition(config, tasks):
dep = list(task["dependent-tasks"].values())[0]
task.setdefault("treeherder", {}).update(inherit_treeherder_from_dep(task, dep))
job_group = dep.task["extra"]["treeherder"].get("groupSymbol", "?")
task_group = dep.task["extra"]["treeherder"].get("groupSymbol", "?")
job_symbol = task["treeherder"].pop("job-symbol")
full_symbol = join_symbol(job_group, job_symbol)
full_symbol = join_symbol(task_group, job_symbol)
task["treeherder"]["symbol"] = full_symbol
yield task
......@@ -24,7 +24,7 @@ only-for-build-types:
group-by: component
job-template:
task-template:
description: Publish component
maven-destination: 'maven2/org/mozilla/components/{component}/{version}/{artifact_file_name}'
run-on-tasks-for: []
......
......@@ -85,14 +85,14 @@ task-defaults:
- ':{component}:publish'
default:
by-component:
# No lintRelease on this job, gradle task isn't defined
# No lintRelease on this task, gradle task isn't defined
tooling-lint:
- ':{component}:assemble'
- ':{component}:assembleAndroidTest'
- ':{component}:test'
- ':{component}:lint'
- 'githubBuildDetails'
# No testRelease on this job, gradle task isn't defined
# No testRelease on this task, gradle task isn't defined
tooling-detekt:
- ':{component}:assemble'
- ':{component}:assembleAndroidTest'
......
......@@ -18,7 +18,7 @@ only-for-build-types:
group-by: build-type
job-template:
task-template:
description: Create/Update Github release
worker-type: github
worker:
......
......@@ -19,7 +19,7 @@ group-by: build-type
only-for-build-types:
- release
job-template:
task-template:
description: Mark Android-Components as shipped in ship-it
worker-type: ship-it
scopes:
......
......@@ -15,7 +15,7 @@ kind-dependencies:
group-by: build-type
job-template:
task-template:
description: Dummy task to wait on all builds before publishing them
worker-type: succeed
treeherder:
......
......@@ -15,7 +15,7 @@ kind-dependencies:
group-by: build-type
job-template:
task-template:
description: Dummy task to wait on all builds before publishing them
worker-type: succeed
treeherder:
......
......@@ -21,7 +21,7 @@ only-for-build-types:
- release
- nightly
job-template:
task-template:
description: Sign component
index:
by-build-type:
......
......@@ -18,7 +18,7 @@ group-by: build-type
only-for-build-types:
- release
job-template:
task-template:
description: Android-components version bump/tag
worker-type: tree
worker:
......
......@@ -3,4 +3,4 @@
mozilla-version
redo
taskcluster-taskgraph
taskcluster-taskgraph >= 3.2.0
#
# This file is autogenerated by pip-compile with python 3.7
# This file is autogenerated by pip-compile with python 3.8
# To update, run:
#
# pip-compile --generate-hashes --output-file=requirements.txt requirements.in
......@@ -14,9 +14,9 @@ attrs==22.1.0 \
# via
# mozilla-version
# taskcluster-taskgraph
certifi==2022.6.15 \
--hash=sha256:84c85a9078b11105f04f3036a9482ae10e4621616db313fe045dd24743a0820d \
--hash=sha256:fe86415d55e84719d75f8b69414f6438ac3547d2078ab91b67e779ef69378412
certifi==2022.9.14 \
--hash=sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5 \
--hash=sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516
# via requests
charset-normalizer==2.1.1 \
--hash=sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845 \
......@@ -25,19 +25,28 @@ charset-normalizer==2.1.1 \
future==0.18.2 \
--hash=sha256:b1bead90b70cf6ec3f0710ae53a525360fa360d306a86583adc6bf83a4db537d
# via mozilla-version
idna==3.3 \
--hash=sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff \
--hash=sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d
giturlparse==0.10.0 \
--hash=sha256:04ba1a3a099c3093fa8d24a422913c6a9b2c2cd22bcffc939cf72e3e98f672d7 \
--hash=sha256:2595ab291d30717cda8474b874c9fd509f1b9802ad7f6968c36a45e4b13eb337
# via mozilla-repo-urls
idna==3.4 \
--hash=sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4 \
--hash=sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2
# via requests
json-e==4.4.3 \
--hash=sha256:604cc506746ece244e5f4c66ce1b77887b0340749f9f10f58f311caf5701315f \
--hash=sha256:8ed3974faa887ca96a7987298f6550cf2ad35472419a980766b3abe48258de0a
# via taskcluster-taskgraph
mozilla-repo-urls==0.0.3 \
--hash=sha256:3b2f9b42111ce3d50ecdcd081a62229e1fdc8f5472adbf405abe12d3ba8e8af5 \
--hash=sha256:673c80a4d0ed449093203b88e119e0bf1074026f891c1dd50aa04d534fd0658c
# via taskcluster-taskgraph
mozilla-version==1.1.0 \
--hash=sha256:1a56c1ea668ec10e18c0a2e394a79373b5ec0ea25a33d204ac6382f337cb9f8a \
--hash=sha256:1fdd9ed90eeec801852b981e98d5b4f6a69efee32eb5f492db86be97393ce4e9
# via -r requirements.in
pyyaml==6.0 \
--hash=sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf \
--hash=sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293 \
--hash=sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b \
--hash=sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57 \
......@@ -49,26 +58,32 @@ pyyaml==6.0 \
--hash=sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287 \
--hash=sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513 \
--hash=sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0 \
--hash=sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782 \
--hash=sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0 \
--hash=sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92 \
--hash=sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f \
--hash=sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2 \
--hash=sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc \
--hash=sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1 \
--hash=sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c \
--hash=sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86 \
--hash=sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4 \
--hash=sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c \
--hash=sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34 \
--hash=sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b \
--hash=sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d \
--hash=sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c \
--hash=sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb \
--hash=sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7 \
--hash=sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737 \
--hash=sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3 \
--hash=sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d \
--hash=sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358 \
--hash=sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53 \
--hash=sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78 \
--hash=sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803 \
--hash=sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a \
--hash=sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f \
--hash=sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174 \
--hash=sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5
# via taskcluster-taskgraph
......@@ -91,9 +106,9 @@ slugid==2.0.0 \
--hash=sha256:a950d98b72691178bdd4d6c52743c4a2aa039207cf7a97d71060a111ff9ba297 \
--hash=sha256:aec8b0e01c4ad32e38e12d609eab3ec912fd129aaf6b2ded0199b56a5f8fd67c
# via taskcluster-taskgraph
taskcluster-taskgraph==3.0.1 \
--hash=sha256:02501d705e2d61a8d38d39b12058aeccfdd2ec8f0c66730d8fd5b70717f1f785 \
--hash=sha256:f2d4e114eb418c3ce2da289e7e49debde0c1a630873b3df354b379be5606a7ec
taskcluster-taskgraph==3.2.0 \
--hash=sha256:941d96fd36c20b0e84e322d2c25be04fe5f258405793af5e086bbec698cbcb17 \
--hash=sha256:fafcd1bfd8ec8b2f57db4e4d87d5b881da3ad7119d78d407d22b4b71b805d1bf
# via -r requirements.in
taskcluster-urls==13.0.1 \
--hash=sha256:5e25e7e6818e8877178b175ff43d2e6548afad72694aa125f404a7329ece0973 \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment