- Notifications
You must be signed in to change notification settings - Fork28.8k
Closed
Description
Steps to reproduce
- Create a flutter (Android) project
- Add flavors with mixed/upper casing (Dev, Prd, for example)
- Add github workflow running on ubuntu
- Add action
flutter build aab --flavor <flavor name> --release
- Trigger the workflow on github
Expected results
The following output:
Running Gradle task'assembleDevRelease'... 666.7s✓ Built build/app/outputs/flutter-apk/app-Dev-release.apk (31.9MB)
Actual results
Output like this:
Running Gradle task'bundleDevRelease'... 1188.4sGradle build failed to produce an .aab file. It's likely that this file was generated under /home/runner/work/path/to/build, but the tool couldn't find it.
On further examination I found that the aab is actually being build so the gradle steps went well. But after that the Flutter-tool was not able to find it.
I also found an issue on the internet where someone had the same error, but for a different reason. But this person mentioned the tool is looking at specific locations:
and Flutter build command: flutter build appbundle --release --flavor exampleProd --verbose flutter_tools is lookingfor the AAB file in:build/app/outputs/bundle/release/app.aabbuild/app/outputs/bundle/release/app-release.aabbuild/app/outputs/bundle/exampleprodRelease/app.aabbuild/app/outputs/bundle/exampleprodRelease/app-exampleprod-release.aab
So I noticed that these paths are all lower case, but the aab outputted by gradle isn't.
Then I found out ubuntu is case sensitive and that might be the reason why it was unable to find it.
I switched to an macos runner and then it works.
Code sample
Code sample
[Paste your code here]
Screenshots or Video
Screenshots / Video demonstration
[Upload media here]
Logs
Logs
[Paste your logs here]
Flutter Doctor output
Doctor output
[Paste your output here]