I am using AGP 8.7.1
with Android Studio Ladybug:
Android Studio Ladybug | 2024.2.1 Patch 1
Build #AI-242.23339.11.2421.12483815, built on October 10, 2024
Runtime version: 21.0.3+-79915917-b509.11 aarch64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Toolkit: sun.lwawt.macosx.LWCToolkit
macOS 14.7
GC: G1 Young Generation, G1 Concurrent GC, G1 Old Generation
Memory: 5120M
Cores: 10
Metal Rendering is ON
Registry:
ide.instant.shutdown=false
ide.experimental.ui=true
i18n.locale=
Non-Bundled Plugins:
idea.plugin.protoeditor (242.23339.11)
io.github.composegears.valkyrie (0.9.1)
org.norbye.tor.kdocformatter (1.6.5)
com.jetbrains.kmm (0.8.3(242)-4)
org.jetbrains.compose.desktop.ide (1.7.0)
I have a project that works great with a debug
build. I set up signing for the release
build using a custom keystore, and when I run it, I get a cryptic error message centered around INSTALL_BASELINE_PROFILE_FAILED
:
The application could not be installed: INSTALL_BASELINE_PROFILE_FAILED Installation failed due to: ‘Baseline profile did not install"
Why am I getting this and what can I do to fix it?
2
Answers
You already have a build installed on this device with the same
applicationId
but a different signing key. A common scenario for this: you have adebug
build signed by your normal debug keystore. Android is trying to install a replacement build with a different signing key, and that will not work.Assuming that you want to be able to use both builds on the same device, you need to give them distinct
applicationId
values. For thedebug
scenario described above, the simple solution is to useapplicationIdSuffix
:(the above is for
build.gradle.kts
; adjust as needed forbuild.gradle
and Groovy syntax)Now, if your
applicationId
indefaultConfig
iscom.commonsware.awesomeapp
, yourdebug
build will get anapplicationId
ofcom.commonsware.awesomeapp.debug
. Now you can have both yourdebug
and yourrelease
builds installed side by side with different signing keys.For me, it started happening while installing on Android 15 devices.
In the Run debug configuration, Selecting APK from app bundle solved the issue