Remove unused recipes and modules. Some recipes and modules are not used anymore. This CL is removing them. Change-Id: I8ca94563e508b3d08b78141e7ed30cd543fec684 Reviewed-on: https://flutter-review.googlesource.com/c/recipes/+/36861 Commit-Queue: Godofredo Contreras <godofredoc@google.com> Reviewed-by: Yusuf Mohsinally <mohsinally@google.com>
diff --git a/recipes/engine/release_builder.expected/basic_linux.json b/recipes/engine/release_builder.expected/basic_linux.json deleted file mode 100644 index 26709ed..0000000 --- a/recipes/engine/release_builder.expected/basic_linux.json +++ /dev/null
@@ -1,534 +0,0 @@ -[ - { - "cmd": [], - "name": "Checkout flutter/mirrors/engine" - }, - { - "cmd": [ - "python3", - "-u", - "RECIPE_MODULE[depot_tools::git]/resources/git_setup.py", - "--path", - "[START_DIR]/mirrors/engine", - "--url", - "https://flutter.googlesource.com/mirrors/engine" - ], - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.git setup", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "git", - "fetch", - "origin", - "main", - "--recurse-submodules", - "--progress", - "--tags" - ], - "cwd": "[START_DIR]/mirrors/engine", - "env": { - "PATH": "RECIPE_REPO[depot_tools]:<PATH>" - }, - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.git fetch", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "git", - "checkout", - "-f", - "FETCH_HEAD" - ], - "cwd": "[START_DIR]/mirrors/engine", - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.git checkout", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "git", - "rev-parse", - "HEAD" - ], - "cwd": "[START_DIR]/mirrors/engine", - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.read revision", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@", - "@@@STEP_TEXT@<br/>checked out 'deadbeef'<br/>@@@", - "@@@SET_BUILD_PROPERTY@got_revision@\"deadbeef\"@@@" - ] - }, - { - "cmd": [ - "git", - "clean", - "-f", - "-d", - "-x" - ], - "cwd": "[START_DIR]/mirrors/engine", - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.git clean", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "git", - "submodule", - "sync" - ], - "cwd": "[START_DIR]/mirrors/engine", - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.submodule sync", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "git", - "submodule", - "update", - "--init", - "--recursive" - ], - "cwd": "[START_DIR]/mirrors/engine", - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "Checkout flutter/mirrors/engine.submodule update", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [], - "name": "read ci yaml", - "~followup_annotations": [ - "@@@STEP_LOG_LINE@yaml@@@@", - "@@@STEP_LOG_END@yaml@@@" - ] - }, - { - "cmd": [ - "vpython3", - "-u", - "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", - "--json-output", - "/path/to/tmp/json", - "copy", - "[START_DIR]/mirrors/engine/.ci.yaml", - "/path/to/tmp/" - ], - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "read ci yaml.read", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@", - "@@@STEP_LOG_END@.ci.yaml@@@" - ] - }, - { - "cmd": [ - "vpython", - "RECIPE_MODULE[flutter::yaml]/resources/parse_yaml.py", - "--yaml_file", - "[START_DIR]/mirrors/engine/.ci.yaml", - "--json_file", - "/path/to/tmp/json" - ], - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "read ci yaml.parse", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@", - "@@@STEP_LOG_LINE@json.output@{@@@", - "@@@STEP_LOG_LINE@json.output@ \"targets\": [@@@", - "@@@STEP_LOG_LINE@json.output@ {@@@", - "@@@STEP_LOG_LINE@json.output@ \"name\": \"linux one\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"properties\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"$flutter/osx_sdk\": \"{\\\"sdk_version\\\": \\\"14a5294e\\\"}\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"release_build\": true@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"recipe\": \"engine/something\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ ]@@@", - "@@@STEP_LOG_LINE@json.output@}@@@", - "@@@STEP_LOG_END@json.output@@@" - ] - }, - { - "cmd": [], - "name": "launch builds" - }, - { - "cmd": [ - "bb", - "batch", - "-host", - "cr-buildbucket.appspot.com" - ], - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "launch builds.schedule", - "stdin": "{\"requests\": [{\"scheduleBuild\": {\"builder\": {\"bucket\": \"try\", \"builder\": \"Linux Engine Drone\", \"project\": \"proj\"}, \"exe\": {\"cipdVersion\": \"refs/heads/main\"}, \"experimental\": \"NO\", \"experiments\": {\"luci.buildbucket.parent_tracking\": false}, \"fields\": \"builder,createTime,createdBy,critical,endTime,id,infra,input,number,output,startTime,status,updateTime\", \"gerritChanges\": [{\"change\": \"123456\", \"host\": \"flutter-review.googlesource.com\", \"patchset\": \"7\", \"project\": \"mirrors/engine\"}], \"gitilesCommit\": {\"host\": \"flutter.googlesource.com\", \"id\": \"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\", \"project\": \"mirrors/engine\", \"ref\": \"refs/heads/main\"}, \"priority\": 25, \"properties\": {\"$flutter/osx_sdk\": {\"sdk_version\": \"14a5294e\"}, \"build\": {\"name\": \"linux one\", \"properties\": {\"$flutter/osx_sdk\": {\"sdk_version\": \"14a5294e\"}}, \"recipe\": \"engine/something\"}, \"environment\": \"Staging\", \"recipe\": \"engine/something\", \"repository\": \"engine\"}, \"requestId\": \"8945511751514863184-00000000-0000-0000-0000-000000001337\", \"swarming\": {\"parentRunId\": \"fake-task-id\"}, \"tags\": [{\"key\": \"cq_experimental\", \"value\": \"false\"}, {\"key\": \"parent_buildbucket_id\", \"value\": \"8945511751514863184\"}, {\"key\": \"user_agent\", \"value\": \"recipe\"}]}}]}", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@", - "@@@STEP_LOG_LINE@json.output@{@@@", - "@@@STEP_LOG_LINE@json.output@ \"responses\": [@@@", - "@@@STEP_LOG_LINE@json.output@ {@@@", - "@@@STEP_LOG_LINE@json.output@ \"scheduleBuild\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"builder\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"bucket\": \"try\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"builder\": \"builder-subbuild1\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"project\": \"fuchsia\"@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"id\": \"8945511751514863186\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ ]@@@", - "@@@STEP_LOG_LINE@json.output@}@@@", - "@@@STEP_LOG_END@json.output@@@", - "@@@STEP_LOG_LINE@request@{@@@", - "@@@STEP_LOG_LINE@request@ \"requests\": [@@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"scheduleBuild\": {@@@", - "@@@STEP_LOG_LINE@request@ \"builder\": {@@@", - "@@@STEP_LOG_LINE@request@ \"bucket\": \"try\", @@@", - "@@@STEP_LOG_LINE@request@ \"builder\": \"Linux Engine Drone\", @@@", - "@@@STEP_LOG_LINE@request@ \"project\": \"proj\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"exe\": {@@@", - "@@@STEP_LOG_LINE@request@ \"cipdVersion\": \"refs/heads/main\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"experimental\": \"NO\", @@@", - "@@@STEP_LOG_LINE@request@ \"experiments\": {@@@", - "@@@STEP_LOG_LINE@request@ \"luci.buildbucket.parent_tracking\": false@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"fields\": \"builder,createTime,createdBy,critical,endTime,id,infra,input,number,output,startTime,status,updateTime\", @@@", - "@@@STEP_LOG_LINE@request@ \"gerritChanges\": [@@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"change\": \"123456\", @@@", - "@@@STEP_LOG_LINE@request@ \"host\": \"flutter-review.googlesource.com\", @@@", - "@@@STEP_LOG_LINE@request@ \"patchset\": \"7\", @@@", - "@@@STEP_LOG_LINE@request@ \"project\": \"mirrors/engine\"@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ ], @@@", - "@@@STEP_LOG_LINE@request@ \"gitilesCommit\": {@@@", - "@@@STEP_LOG_LINE@request@ \"host\": \"flutter.googlesource.com\", @@@", - "@@@STEP_LOG_LINE@request@ \"id\": \"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\", @@@", - "@@@STEP_LOG_LINE@request@ \"project\": \"mirrors/engine\", @@@", - "@@@STEP_LOG_LINE@request@ \"ref\": \"refs/heads/main\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"priority\": 25, @@@", - "@@@STEP_LOG_LINE@request@ \"properties\": {@@@", - "@@@STEP_LOG_LINE@request@ \"$flutter/osx_sdk\": {@@@", - "@@@STEP_LOG_LINE@request@ \"sdk_version\": \"14a5294e\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"build\": {@@@", - "@@@STEP_LOG_LINE@request@ \"name\": \"linux one\", @@@", - "@@@STEP_LOG_LINE@request@ \"properties\": {@@@", - "@@@STEP_LOG_LINE@request@ \"$flutter/osx_sdk\": {@@@", - "@@@STEP_LOG_LINE@request@ \"sdk_version\": \"14a5294e\"@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"recipe\": \"engine/something\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"environment\": \"Staging\", @@@", - "@@@STEP_LOG_LINE@request@ \"recipe\": \"engine/something\", @@@", - "@@@STEP_LOG_LINE@request@ \"repository\": \"engine\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"requestId\": \"8945511751514863184-00000000-0000-0000-0000-000000001337\", @@@", - "@@@STEP_LOG_LINE@request@ \"swarming\": {@@@", - "@@@STEP_LOG_LINE@request@ \"parentRunId\": \"fake-task-id\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ \"tags\": [@@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"key\": \"cq_experimental\", @@@", - "@@@STEP_LOG_LINE@request@ \"value\": \"false\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"key\": \"parent_buildbucket_id\", @@@", - "@@@STEP_LOG_LINE@request@ \"value\": \"8945511751514863184\"@@@", - "@@@STEP_LOG_LINE@request@ }, @@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"key\": \"user_agent\", @@@", - "@@@STEP_LOG_LINE@request@ \"value\": \"recipe\"@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ ]@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ ]@@@", - "@@@STEP_LOG_LINE@request@}@@@", - "@@@STEP_LOG_END@request@@@", - "@@@STEP_LINK@8945511751514863186@https://cr-buildbucket.appspot.com/build/8945511751514863186@@@" - ] - }, - { - "cmd": [], - "name": "collect builds" - }, - { - "cmd": [], - "name": "collect builds.collect", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@" - ] - }, - { - "cmd": [ - "bb", - "collect", - "-host", - "cr-buildbucket.appspot.com", - "-interval", - "20s", - "8945511751514863186" - ], - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "collect builds.collect.wait", - "timeout": 86400, - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@2@@@" - ] - }, - { - "cmd": [ - "bb", - "batch", - "-host", - "cr-buildbucket.appspot.com" - ], - "infra_step": true, - "luci_context": { - "realm": { - "name": "proj:try" - }, - "resultdb": { - "current_invocation": { - "name": "invocations/build:8945511751514863184", - "update_token": "token" - }, - "hostname": "rdbhost" - } - }, - "name": "collect builds.collect.get", - "stdin": "{\"requests\": [{\"getBuild\": {\"fields\": \"builder,createTime,createdBy,critical,endTime,id,infra,infra.swarming.taskId,input,number,output,startTime,status,summaryMarkdown,updateTime\", \"id\": \"8945511751514863186\"}}]}", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@2@@@", - "@@@STEP_LOG_LINE@json.output@{@@@", - "@@@STEP_LOG_LINE@json.output@ \"responses\": [@@@", - "@@@STEP_LOG_LINE@json.output@ {@@@", - "@@@STEP_LOG_LINE@json.output@ \"getBuild\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"builder\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"bucket\": \"try\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"builder\": \"builder-subbuild1\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"project\": \"fuchsia\"@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"createTime\": \"2018-05-25T23:50:17Z\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"createdBy\": \"project:fuchsia\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"id\": \"8945511751514863186\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"infra\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"resultdb\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"invocation\": \"invocations/build:8945511751514863186\"@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"swarming\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"priority\": 30, @@@", - "@@@STEP_LOG_LINE@json.output@ \"taskId\": \"abc123\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"input\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"gerritChanges\": [@@@", - "@@@STEP_LOG_LINE@json.output@ {@@@", - "@@@STEP_LOG_LINE@json.output@ \"change\": \"123456\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"host\": \"chromium-review.googlesource.com\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"patchset\": \"7\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"project\": \"fuchsia\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ ]@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"output\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"properties\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"test_orchestration_inputs_hash\": \"abc\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ }, @@@", - "@@@STEP_LOG_LINE@json.output@ \"status\": \"SUCCESS\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"tags\": [@@@", - "@@@STEP_LOG_LINE@json.output@ {@@@", - "@@@STEP_LOG_LINE@json.output@ \"key\": \"cq_experimental\", @@@", - "@@@STEP_LOG_LINE@json.output@ \"value\": \"false\"@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ ]@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ }@@@", - "@@@STEP_LOG_LINE@json.output@ ]@@@", - "@@@STEP_LOG_LINE@json.output@}@@@", - "@@@STEP_LOG_END@json.output@@@", - "@@@STEP_LOG_LINE@request@{@@@", - "@@@STEP_LOG_LINE@request@ \"requests\": [@@@", - "@@@STEP_LOG_LINE@request@ {@@@", - "@@@STEP_LOG_LINE@request@ \"getBuild\": {@@@", - "@@@STEP_LOG_LINE@request@ \"fields\": \"builder,createTime,createdBy,critical,endTime,id,infra,infra.swarming.taskId,input,number,output,startTime,status,summaryMarkdown,updateTime\", @@@", - "@@@STEP_LOG_LINE@request@ \"id\": \"8945511751514863186\"@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ }@@@", - "@@@STEP_LOG_LINE@request@ ]@@@", - "@@@STEP_LOG_LINE@request@}@@@", - "@@@STEP_LOG_END@request@@@", - "@@@STEP_LINK@8945511751514863186@https://cr-buildbucket.appspot.com/build/8945511751514863186@@@" - ] - }, - { - "cmd": [], - "name": "display builds" - }, - { - "cmd": [], - "name": "display builds.linux one", - "~followup_annotations": [ - "@@@STEP_NEST_LEVEL@1@@@", - "@@@STEP_LINK@8945511751514863186@https://cr-buildbucket.appspot.com/build/8945511751514863186@@@" - ] - }, - { - "name": "$result" - } -] \ No newline at end of file
diff --git a/recipes/engine/release_builder.py b/recipes/engine/release_builder.py deleted file mode 100644 index 5686e25..0000000 --- a/recipes/engine/release_builder.py +++ /dev/null
@@ -1,107 +0,0 @@ -# Copyright 2022 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# Orchestrator recipe that runs subbuilds required to release engine. -# -# This recipe reads <engine_checkout>/.ci_yaml, and for every target -# marked with release_build: true, and spawens a subbuild. - - -import json -from contextlib import contextmanager - -from PB.recipes.flutter.engine.engine import InputProperties -from PB.recipes.flutter.engine.engine import EnvProperties - -from RECIPE_MODULES.flutter.repo_util.api import REPOS - -from google.protobuf import struct_pb2 - -DEPS = [ - 'flutter/yaml', - 'flutter/display_util', - 'flutter/repo_util', - 'flutter/shard_util_v2', - 'recipe_engine/buildbucket', - 'recipe_engine/json', - 'recipe_engine/path', - 'recipe_engine/platform', - 'recipe_engine/properties', - 'recipe_engine/step', -] - -GIT_REPO = \ - 'https://flutter.googlesource.com/mirrors/engine' - - -PROPERTIES = InputProperties -ENV_PROPERTIES = EnvProperties - - -def RunSteps(api, properties, env_properties): - repository = api.buildbucket.gitiles_commit.project - checkout_path = api.path['start_dir'].join(repository) - git_ref = api.properties.get('git_ref') or api.buildbucket.gitiles_commit.ref - git_url = api.properties.get('git_url') or REPOS[repository] - api.repo_util.checkout( - repository, - checkout_path=checkout_path, - url=git_url, - ref=git_ref - ) - - ci_yaml_path = checkout_path.join('.ci.yaml') - ci_yaml = api.yaml.read('read ci yaml', ci_yaml_path, api.json.output()) - - # Foreach target defined in .ci.yaml, if it contains - # release_build: True, then spawn a subbuild. - tasks = {} - build_results = [] - with api.step.nest('launch builds') as presentation: - for target in ci_yaml.json.output['targets']: - if target.get("properties", {}).get("release_build", False) and ( - target["name"].lower().startswith(api.platform.name)): - target = api.shard_util_v2.pre_process_properties(target) - tasks.update(api.shard_util_v2.schedule( - [target, ], target["recipe"], presentation)) - with api.step.nest('collect builds') as presentation: - build_results = api.shard_util_v2.collect(tasks, presentation) - - api.display_util.display_subbuilds( - step_name='display builds', - subbuilds=build_results, - raise_on_failure=True, - ) - - -def GenTests(api): - try_subbuild1 = api.shard_util_v2.try_build_message( - build_id=8945511751514863186, - builder="builder-subbuild1", - output_props={"test_orchestration_inputs_hash": "abc"}, - status="SUCCESS", - ) - tasks_dict = {'targets': [ - {'name': 'linux one', 'recipe': 'engine/something', - 'properties': {'release_build': True, '$flutter/osx_sdk': '{"sdk_version": "14a5294e"}'} - }] - } - yield api.test( - 'basic_linux', - api.platform.name('linux'), - api.properties(environment='Staging', repository='engine'), - api.buildbucket.try_build( - project='proj', - builder='try-builder', - git_repo='https://flutter.googlesource.com/mirrors/engine', - revision='a' * 40, - build_number=123, - ), - api.shard_util_v2.child_build_steps( - subbuilds=[try_subbuild1], - launch_step="launch builds", - collect_step="collect builds", - ), - api.step_data('read ci yaml.parse', api.json.output(tasks_dict)) - )