[CP-stable]Skip wasm build when dry run is disabled and --wasm is not specified.#174263
Conversation
…flutter#174184) This fixes an issue where the wasm build was still getting executed when `--no-wasm-dry-run` was specified. Also adds a test to verify the expected behavior. Co-authored-by: Nate Biggs <[email protected]>
|
@mdebbar please fill out the PR description above, afterwards the release team will review this request. |
|
This pull request was opened from and to a release candidate branch. This should only be done as part of the official Flutter release process. If you are attempting to make a regular contribution to the Flutter project, please close this PR and follow the instructions at Tree Hygiene for detailed instructions on contributing to Flutter. Reviewers: Use caution before merging pull requests to release branches. Ensure the proper procedure has been followed. |
There was a problem hiding this comment.
Code Review
This pull request modifies the web build command to conditionally skip the WebAssembly (Wasm) dry-run compilation for JavaScript-only builds. The change in packages/flutter_tools/lib/src/commands/build_web.dart makes the inclusion of WasmCompilerConfig dependent on the wasm-dry-run flag. When this flag is disabled via --no-wasm-dry-run, the Wasm compilation step is omitted. A new test case in packages/flutter_tools/test/commands.shard/hermetic/build_web_test.dart has been added to validate this behavior. The logic correctly implements the intended behavior, and the new test sufficiently covers the change.
e3dff51
into
flutter:flutter-3.35-candidate.0
…m is not specified. (flutter/flutter#174263)
This pull request is created by automatic cherry pick workflow
Please fill in the form below, and a flutter domain expert will evaluate this cherry pick request.
Issue Link:
What is the link to the issue this cherry-pick is addressing?
< Replace with issue link here >
Changelog Description:
Explain this cherry pick in one line that is accessible to most Flutter developers. See best practices for examples
< Replace with changelog description here >
Impact Description:
What is the impact (ex. visual jank on Samsung phones, app crash, cannot ship an iOS app)? Does it impact development (ex. flutter doctor crashes when Android Studio is installed), or the shipping production app (the app crashes on launch)
< Replace with impact description here >
Workaround:
Is there a workaround for this issue?
< Replace with workaround here >
Risk:
What is the risk level of this cherry-pick?
Test Coverage:
Are you confident that your fix is well-tested by automated tests?
Validation Steps:
What are the steps to validate that this fix works?
< Replace with validation steps here >