Context
build.yml takes a flavor input (development/staging/production,
default development) and passes it to flutter build. But
android/app/build.gradle.kts defines no product flavors, so:
FAILURE: Build failed with an exception.
* What went wrong:
Task 'assembleDevelopmentRelease' not found in root project 'android' and its subprojects.
[!] Gradle project does not define a task suitable for the requested build.
The android/app/build.gradle.kts file does not define any custom product
flavors. You cannot use the --flavor option.
Evidence: run 32966668310
(platform=android, flavor=development).
The web build in the same workflow succeeded, so this was masked - only the
Android and iOS paths consume --flavor.
Discovered while safety-checking an unrelated Gradle edit for #30. Not caused by
that change: Gradle configured successfully and then could not find the task.
Scope
Check every --flavor consumer:
Two honest options
- Define the flavors. Add
flavorDimensions and
productFlavors { development / staging / production } to
android/app/build.gradle.kts, plus the iOS scheme equivalents. Makes the
workflow inputs real. More surface for a starter to carry, and iOS schemes
cannot be created from a script here.
- Drop the flavor inputs. Remove
--flavor from the workflows and use the
existing --dart-define / .env layering, which is what
docs/guides/configuration.md already describes as the configuration
mechanism. Simpler, and matches how the project actually configures itself.
Option 2 looks right: the repo's documented configuration story is env layering
plus dart-defines, not Gradle flavors. But this changes a documented workflow
input, so it wants a decision.
Acceptance criteria
grep -rn '\-\-flavor' .github/workflows/ is consistent with reality: either
every referenced flavor exists as a product flavor, or --flavor is gone.
- A
workflow_dispatch run of build.yml with platform=android succeeds
and uploads an APK artifact. Record the run id.
- A
workflow_dispatch run of build.yml with platform=web still succeeds
(it does today - do not regress it).
- If the
flavor input is removed, build.yml's input list and any doc that
mentions choosing a flavor are updated together.
deploy-android.yml and deploy-ios.yml are made consistent with whichever
option is chosen, even though they cannot be dispatched here (they publish).
State that they were not run.
./scripts/dev/audit_template.sh exits 0.
Context
build.ymltakes aflavorinput (development/staging/production,default
development) and passes it toflutter build. Butandroid/app/build.gradle.ktsdefines no product flavors, so:Evidence: run 32966668310
(
platform=android,flavor=development).The web build in the same workflow succeeded, so this was masked - only the
Android and iOS paths consume
--flavor.Discovered while safety-checking an unrelated Gradle edit for #30. Not caused by
that change: Gradle configured successfully and then could not find the task.
Scope
Check every
--flavorconsumer:build.yml(Build Android, Build iOS)deploy-android.yml,deploy-ios.yml- these also declare a flavor and havenever got past Setup Flutter until fix(tooling): flutter-version: 'stable' breaks Setup Flutter in 5 more workflows #24, so their flavor handling has never
been exercised either.
Two honest options
flavorDimensionsandproductFlavors { development / staging / production }toandroid/app/build.gradle.kts, plus the iOS scheme equivalents. Makes theworkflow inputs real. More surface for a starter to carry, and iOS schemes
cannot be created from a script here.
--flavorfrom the workflows and use theexisting
--dart-define/.envlayering, which is whatdocs/guides/configuration.mdalready describes as the configurationmechanism. Simpler, and matches how the project actually configures itself.
Option 2 looks right: the repo's documented configuration story is env layering
plus dart-defines, not Gradle flavors. But this changes a documented workflow
input, so it wants a decision.
Acceptance criteria
grep -rn '\-\-flavor' .github/workflows/is consistent with reality: eitherevery referenced flavor exists as a product flavor, or
--flavoris gone.workflow_dispatchrun ofbuild.ymlwithplatform=androidsucceedsand uploads an APK artifact. Record the run id.
workflow_dispatchrun ofbuild.ymlwithplatform=webstill succeeds(it does today - do not regress it).
flavorinput is removed,build.yml's input list and any doc thatmentions choosing a flavor are updated together.
deploy-android.ymlanddeploy-ios.ymlare made consistent with whicheveroption is chosen, even though they cannot be dispatched here (they publish).
State that they were not run.
./scripts/dev/audit_template.shexits 0.