You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Android Studio Iguana | 2023.2.1 Patch 1
Build #AI-232.10300.40.2321.11567975, built on March 13, 2024
Runtime version: 17.0.9+0-17.0.9b1087.7-11185874 aarch64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 14.2.1
GC: G1 Young Generation, G1 Old Generation
Memory: 16384M
Cores: 10
Metal Rendering is ON
Registry:
ide.instant.shutdown=false
ide.experimental.ui=true
Non-Bundled Plugins:
com.github.copilot (1.5.1.5285)
(1) My app has 3 build types and 3 product flavors, thus there're 9 build variants.
build types: debug, internal, release
product flavors(region): us, eu, tw; Each of them has an unique application ID.
(2) My app uses plugin com.google.gms.google-services so there're 9 google-play-services.json files for each variant.
(3) After created a new baselineprofile module by Baseline Profile Generator on Android Studio Iguana (to :app:baselineprofile), it added NonMinified and Benchmark for non-debug builds, so I got 12(=(3-1)x3x2) more build variants.
Because of (2)+(3), I'll need to create 12 more folders for new variants to place each google-play-services.json file.
What went wrong:
Execution failed for task ':app:processUsNonMinifiedInternalGoogleServices'.
File google-services.json is missing.
The Google Services Plugin cannot function without it.
Searched locations: ...
Is it expected? Any suggestions?
Question 2
The generator in Android Studio created baselineprofile under app with a build.gradle.kts which defined productFlavors(us/eu/tw), but didn't define buildTypes(debug/internal/release). So the error message is like this:
Could not determine the dependencies of task ':app:mergeUsInternalBaselineProfile'.
Could not resolve all task dependencies for configuration ':app:usInternalBaselineProfile'.
Could not resolve project :app:baselineprofile.
Required by:
project :app
> No matching variant of project :app:baselineprofile was found. The consumer was configured to find a component for use during 'baselineProfile', preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'internal', attribute 'com.android.build.api.attributes.ProductFlavor:region' with value 'us', attribute 'androidx.baselineprofile.gradle.configuration.attribute.BaselineProfilePluginAgpVersionAttr' with value '8.2.0', attribute 'androidx.baselineprofile.gradle.configuration.attribute.BaselineProfilePluginVersionAttr' with value 'alpha1' but:
...
In StartupBenchmarks.kt and BaselineProfileGenerator.kt, the package name is hardcoded. What's the recommendation for multiple apps? By separating src folders?
Thanks :D
The text was updated successfully, but these errors were encountered:
Env:
Question 1
(1) My app has 3 build types and 3 product flavors, thus there're 9 build variants.
(2) My app uses plugin
com.google.gms.google-services
so there're 9google-play-services.json
files for each variant.(3) After created a new baselineprofile module by Baseline Profile Generator on Android Studio Iguana (to
:app:baselineprofile
), it addedNonMinified
andBenchmark
for non-debug builds, so I got 12(=(3-1)x3x2) more build variants.Because of (2)+(3), I'll need to create 12 more folders for new variants to place each
google-play-services.json
file.Example
NonMinified
Internal/google-play-services.jsonNonMinified
Release/google-play-services.jsonBenchmark
Internal/google-play-services.jsonBenchmark
Release/google-play-services.jsonOtherwise the error is
Is it expected? Any suggestions?
Question 2
The generator in Android Studio created
baselineprofile
underapp
with a build.gradle.kts which defined productFlavors(us/eu/tw), but didn't define buildTypes(debug/internal/release). So the error message is like this:Question 3
mergeIntoMain
must be inapp/build.gradle.kts
instead ofapp/baselineprofile/build.gradle.kts
, is it expected?It seems reasonable, just doesn't mention in https://developer.android.com/topic/performance/baselineprofiles/configure-baselineprofiles#generate-for-variants
There are many build.gradle.kts files in a repo, and sometimes the doc doesn't specify.
Question 4
In StartupBenchmarks.kt and BaselineProfileGenerator.kt, the package name is hardcoded. What's the recommendation for multiple apps? By separating src folders?
Thanks :D
The text was updated successfully, but these errors were encountered: