diff --git a/taskcluster/ci/system-symbols-upload/kind.yml b/taskcluster/ci/system-symbols-upload/kind.yml index 66d7c65f2466..ac2a4f2007a8 100644 --- a/taskcluster/ci/system-symbols-upload/kind.yml +++ b/taskcluster/ci/system-symbols-upload/kind.yml @@ -2,30 +2,33 @@ # 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/. --- -loader: gecko_taskgraph.loader.single_dep:loader +loader: gecko_taskgraph.loader.transform:loader transforms: - - gecko_taskgraph.transforms.upload_symbols:transforms - - gecko_taskgraph.transforms.job:transforms - - gecko_taskgraph.transforms.task:transforms + - taskgraph.transforms.from_deps + - gecko_taskgraph.transforms.upload_symbols + - gecko_taskgraph.transforms.job + - gecko_taskgraph.transforms.task kind-dependencies: - system-symbols -job-template: - description: Upload Symbols - attributes: - cron: true - worker-type: b-linux-gcp - worker: - docker-image: {in-tree: "lint"} - max-run-time: 1200 - env: - # {level} gets replaced in the upload_symbols transform - SYMBOL_SECRET: "project/releng/gecko/build/level-{level}/gecko-symbol-upload" - run: - using: mach - mach: {artifact-reference: "python toolkit/crashreporter/tools/upload_symbols.py --ignore-missing"} - sparse-profile: upload-symbols - scopes: - - secrets:get:project/releng/gecko/build/level-{level}/gecko-symbol-upload +jobs: + system-symbols-upload: + description: Upload Symbols + from-deps: {} + attributes: + cron: true + worker-type: b-linux-gcp + worker: + docker-image: {in-tree: "lint"} + max-run-time: 1200 + env: + # {level} gets replaced in the upload_symbols transform + SYMBOL_SECRET: "project/releng/gecko/build/level-{level}/gecko-symbol-upload" + run: + using: mach + mach: {artifact-reference: "python toolkit/crashreporter/tools/upload_symbols.py --ignore-missing"} + sparse-profile: upload-symbols + scopes: + - secrets:get:project/releng/gecko/build/level-{level}/gecko-symbol-upload diff --git a/taskcluster/ci/upload-symbols/kind.yml b/taskcluster/ci/upload-symbols/kind.yml index 2948dc0abd49..2a1b380f5768 100644 --- a/taskcluster/ci/upload-symbols/kind.yml +++ b/taskcluster/ci/upload-symbols/kind.yml @@ -2,21 +2,18 @@ # 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/. --- -loader: gecko_taskgraph.loader.multi_dep:loader - -group-by: platform +loader: gecko_taskgraph.loader.transform:loader transforms: - - gecko_taskgraph.transforms.upload_symbols:transforms - - gecko_taskgraph.transforms.job:transforms - - gecko_taskgraph.transforms.task:transforms + - taskgraph.transforms.from_deps + - gecko_taskgraph.transforms.upload_symbols + - gecko_taskgraph.transforms.job + - gecko_taskgraph.transforms.task kind-dependencies: - build - toolchain -primary-dependency: build - not-for-build-platforms: # Address Sanitizer builds don't have symbols to upload. - linux64-asan-reporter-shippable/opt @@ -30,24 +27,27 @@ not-for-build-platforms: - win64-geckodriver/opt - win64-aarch64-geckodriver/opt -job-template: - description: Upload Symbols - worker-type: b-linux-gcp - use-system-python: false - worker: - docker-image: {in-tree: "debian11-base"} - max-run-time: 1800 - env: - # {level} gets replaced in the upload_symbols transform - SYMBOL_SECRET: "project/releng/gecko/build/level-{level}/gecko-symbol-upload" - MAKECAB: /builds/worker/fetches/makecab/makecab - MACH_BUILD_PYTHON_NATIVE_PACKAGE_SOURCE: system - run: - using: mach - mach: {artifact-reference: "python toolkit/crashreporter/tools/upload_symbols.py "} - sparse-profile: upload-symbols - scopes: - - secrets:get:project/releng/gecko/build/level-{level}/gecko-symbol-upload - fetches: - toolchain: - - linux64-makecab +jobs: + upload-symbols: + description: Upload Symbols + from-deps: + group-by: platform + worker-type: b-linux-gcp + use-system-python: false + worker: + docker-image: {in-tree: "debian11-base"} + max-run-time: 1800 + env: + # {level} gets replaced in the upload_symbols transform + SYMBOL_SECRET: "project/releng/gecko/build/level-{level}/gecko-symbol-upload" + MAKECAB: /builds/worker/fetches/makecab/makecab + MACH_BUILD_PYTHON_NATIVE_PACKAGE_SOURCE: system + run: + using: mach + mach: {artifact-reference: "python toolkit/crashreporter/tools/upload_symbols.py "} + sparse-profile: upload-symbols + scopes: + - secrets:get:project/releng/gecko/build/level-{level}/gecko-symbol-upload + fetches: + toolchain: + - linux64-makecab diff --git a/taskcluster/gecko_taskgraph/transforms/upload_symbols.py b/taskcluster/gecko_taskgraph/transforms/upload_symbols.py index f6d40e9a4560..5c0bf18cb0a2 100644 --- a/taskcluster/gecko_taskgraph/transforms/upload_symbols.py +++ b/taskcluster/gecko_taskgraph/transforms/upload_symbols.py @@ -10,6 +10,7 @@ taskcluster/ci/upload-symbols/job-template.yml into an actual task description. import logging from taskgraph.transforms.base import TransformSequence +from taskgraph.util.dependencies import get_primary_dependency from taskgraph.util.treeherder import inherit_treeherder_from_dep, join_symbol from gecko_taskgraph.util.attributes import ( @@ -30,7 +31,9 @@ def check_nightlies(config, tasks): Putting this check here (instead of the transforms for the build kind) lets us leverage the any not-for-build-platforms set in the update-symbols kind.""" for task in tasks: - dep = task["primary-dependency"] + dep = get_primary_dependency(config, task) + assert dep + if ( config.params["project"] in RELEASE_PROJECTS and dep.attributes.get("shippable") @@ -47,8 +50,8 @@ def check_nightlies(config, tasks): @transforms.add def fill_template(config, tasks): for task in tasks: - dep = task["primary-dependency"] - task.pop("dependent-tasks", None) + dep = get_primary_dependency(config, task) + assert dep # Fill out the dynamic fields in the task description task["label"] = dep.label + "-upload-symbols" @@ -60,7 +63,6 @@ def fill_template(config, tasks): logger.debug("Skipping upload symbols task for %s", task["label"]) continue - task["dependencies"] = {"build": dep.label} task["worker"]["env"]["GECKO_HEAD_REPOSITORY"] = config.params[ "head_repository" ] @@ -87,9 +89,6 @@ def fill_template(config, tasks): # XXX Better to run this on promote phase instead? task["run-on-projects"] = dep.attributes.get("run_on_projects") task["optimization"] = {"upload-symbols": None} - task["if-dependencies"] = ["build"] - - # clear out the stuff that's not part of a task description - del task["primary-dependency"] + task["if-dependencies"] = [task["attributes"]["primary-kind-dependency"]] yield task