Repository navigation
[tool] Warn when rendering backend selection flags are used with release builds - #191083
Merged
Merged
Conversation
…ase builds Flags like `--enable-impeller` and `--no-enable-impeller` are ignored in release builds because the rendering backend is determined at build time. This change adds a warning in `FlutterCommand.verifyThenRunCommand` when these flags are parsed during release builds. Fixes flutter#191027
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a warning in FlutterCommand.verifyThenRunCommand when the --enable-impeller or --no-enable-impeller flag is supplied in release builds, along with corresponding unit tests. However, calling getBuildMode() unconditionally can cause an ArgumentError for commands that do not register build mode flags. It is recommended to check if the command supports build modes before invoking getBuildMode().
chingjun
approved these changes
Aug 13, 2026
This was referenced Aug 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Flags like
--enable-impellerand--no-enable-impellerare ignored in release builds because the rendering backend is determined at build time.This change emits a warning in
FlutterCommand.verifyThenRunCommandwhen these flags are parsed during release builds.Related Issues
Tests
flutter_command_test.dartverifying warnings are emitted for--release --enable-impellerand--release --no-enable-impeller, and not emitted for debug builds or release builds without impeller flags.