Skip to content

Conversation

@matanlurey
Copy link
Contributor

Closes #162703.

I still need to do a similar change for ios|macos-framework in #162704.

I added two unit tests, as well as opted in an integration test to the flag (it will become the default in #160289).

/cc @reidbaker @gmackall.

@github-actions github-actions bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Feb 4, 2025
@matanlurey
Copy link
Contributor Author

Also /cc @sigurdm, this might have impact with your latest changes for workspaces/assets (probably easy to fix, but worth mentioning).

Copy link
Contributor

@camsim99 camsim99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The premise looks good to me! Leaving to @jmagman for final review.

iOS and macOS are failing with the error now looks like though: https://ci.chromium.org/ui/p/flutter/builders/try/Mac%20tool_integration_tests_5_5/6050/overview. This expected?

@matanlurey
Copy link
Contributor Author

The premise looks good to me! Leaving to @jmagman for final review.

iOS and macOS are failing with the error now looks like though: https://ci.chromium.org/ui/p/flutter/builders/try/Mac%20tool_integration_tests_5_5/6050/overview. This expected?

Nope 🥹. I'll take a look at the native asset tests, perhaps they have a different pattern for inheritance or have overwritten something or I misunderstand how verify is being called.

Likely something small

FlutterProject project, {
bool? releaseMode,
}) async {
// Intentionally left blank. We want to rebuild the tooling before every sub-build.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uh ... can you explain this to me?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah. The base class implementation is automatically called in verifyAndRunCommand, but I don't want that to happen in these sub commands. I admit it could probably be done a better way, I was just trying to avoid lots of overridden booleans

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, so the base class is the real thing that we use before each build. BUt then there is also a verfy step that we need to .. for lack of a better term, trick?

If my understanding is correct, we could also override/remove the verify step too right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's essentially what this does, at least the part related to meta tooling. I'm not sure it's safe to skip the entire verify step, but I could be talked into it by someone who understands what it does better 😁

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah this seems simpler, I would expand the documentation to explain it more directly.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I ended up also renaming the function and adding the boolean 🤷🏼

Copy link
Contributor

@jonahwilliams jonahwilliams left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM w/ nit

@matanlurey
Copy link
Contributor Author

matanlurey commented Feb 5, 2025

@camsim99:

iOS and macOS are failing with the error now looks like though: https://ci.chromium.org/ui/p/flutter/builders/try/Mac%20tool_integration_tests_5_5/6050/overview. This expected?

tl;dr, this is because of #162704.

I accidentally started evaluating getBuildMode().isRelease even if isExplicitPackageDependenciesEnabled was not set, which caused these tests to start failing. When #162704 is complete (as a follow-up), then there will no longer be any calls to getBuildMode() for meta-build commands that cause the infamous error message of "expected --release" etc.

@matanlurey
Copy link
Contributor Author

@jmagman I am going to merge this to unblock and start working on flutter build ios-framework and flutter build macos-framework; if you have comments please still leave them and I can address post-submit.

@matanlurey matanlurey added the autosubmit Merge PR when tree becomes green via auto submit App label Feb 6, 2025
@auto-submit auto-submit bot added this pull request to the merge queue Feb 6, 2025
Merged via the queue into flutter:master with commit 0e59f0f Feb 6, 2025
148 checks passed
@flutter-dashboard flutter-dashboard bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Feb 6, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 6, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 6, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 7, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 8, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 8, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 9, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 9, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 10, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 10, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 10, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 10, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 10, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Feb 11, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 20, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 20, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make flutter build aar invoke rengeratePlatformSpecificTooling per build mode

3 participants