Repository navigation
Conditionally skip the engine build phase #162201
Description
We'll use the same logic we use for runIf to determine if the engine sources changed::
DEPSengine/**
If there are >= 30 files or one of the files above changed, we keep doing what we do now (i.e. build the engine before scheduling engine and framework tests).
Otherwise, in this new flow (TM):
-
We support
FLUTTER_PREBUILT_ENGINE_VERSION: -
We set
properties['flutter_prebuilt_engine_version']=github.event.pull_request.base.sha(in Cocoon)MERGED: Pass along flutter_prebuilt_engine_version if so requested cocoon#4177
-
We update LUCI recipes
repo_utils/api.pyto, if provided, useflutter_prebuilt_engine_versionto set the environment variableFLUTTER_ENGINE_VERSION={property}.MERGED: https://flutter-review.googlesource.com/c/recipes/+/62501
-
Edit
triggerPresubmitTargetsto make the request for the list of files before computing presubmit targets.MERGED: Inject a
GetFilesChangedshim instead of usingGithubServicedirectly. cocoon#4178MERGED: Skip engine builds/tests for a framework-only PR (allow-listed) cocoon#4185
This, combined with the work we already did/are doing, see #162118, means that we'll fetch and use an older engine artifact.
There is future work to do to expand beyond the 30 file limit (see #161462), but we believe this would address many framework-only PRs today, allowing us to fix the limitations we have today of understanding what files changed (and eventually move towards something like a precomputed build plan).
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsFixed
- StatusShow more project fieldsDone
Activity
Pass along flutter_prebuilt_engine_version if so requested
jtmcdole commentedon Jan 24, 2025
luci: https://flutter-review.googlesource.com/c/recipes/+/62501
Pass along flutter_prebuilt_engine_version if so requested (#4177)
1 remaining item
jtmcdole commentedon Jan 25, 2025
cocoon: flutter/cocoon#4177
Formalize `update_engine_version.{sh|ps1}`. (#162118)
Skip engine builds/tests for a framework-only PR (allow-listed) (#4185)
jtmcdole commentedon Jan 28, 2025
#162284 shows cocoon working so long as its a short list of allowlisted folks. We have to update the update_engine_version files to not output to stderr or its going to fail linux analyze.
Apparently it is illegal to use `stderr` in this project. (#162294)
jtmcdole commentedon Jan 28, 2025
I've been hit with two things recently:
jtmcdole commentedon Jan 28, 2025
jtmcdole commentedon Jan 28, 2025
Cocoon was using unauthenticated calls to list files at this stage. Fixed: flutter/cocoon#4191
Enable framework-only PR optimizations. (flutter#4190)
github-actions commentedon Feb 11, 2025
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.