GPP is Android's unofficial release automation Gradle Plugin. It can do anything from building, uploading, and then promoting your App Bundle or APK to publishing app listings and other metadata.
MIT License
4.09k
stars
339
forks
source link
Task installRelease not found when publishing is disabled #1103
When play publishing is disabled in configuration then task installRelease can not be found when there are no publishing keys. Without using this 'enabled' parameter it is possible to use this task and install unsigned apk.
When dev have locally set publishing keys it works fine.
How To Reproduce
Having configuration like this:
play {
if (isInLocalEnv()) {
enabled = false
}
track = 'internal'
serviceAccountCredentials = rootProject.file('keystores/google-play-publisher-api-key.json')
}
where isInLocalEnv() is our local function which checks if current build is done on local dev machine.
Then using ./gradlew installRelease we are getting:
`
FAILURE: Build failed with an exception.
What went wrong:
Cannot locate tasks that match ':app:installRelease' as task 'installRelease' not found in project ':app'. Some candidates are: 'uninstallRelease'.
`
what is more interesing task assembleRelease still can be used correctly.
When
if (isInLocalEnv()) { enabled = false }
is removed then it works fine.
This issue has been automatically marked as stale because it has not had recent
activity. It will be closed if no further activity occurs. Thank you for your
contributions.
Describe the bug
When play publishing is disabled in configuration then task installRelease can not be found when there are no publishing keys. Without using this 'enabled' parameter it is possible to use this task and install unsigned apk. When dev have locally set publishing keys it works fine.
How To Reproduce
Having configuration like this:
where isInLocalEnv() is our local function which checks if current build is done on local dev machine.
Then using ./gradlew installRelease we are getting:
` FAILURE: Build failed with an exception.
what is more interesing task assembleRelease still can be used correctly.
When
if (isInLocalEnv()) { enabled = false }
is removed then it works fine.Versions
+--- com.github.triplet.gradle:play-publisher:3.8.4 | +--- com.github.triplet.gradle:android-publisher:3.8.4 | | +--- com.github.triplet.gradle:common-utils:3.8.4 | +--- com.github.triplet.gradle:common-utils:3.8.4 | +--- com.github.triplet.gradle:common-validation:3.8.4
Gradle 8.0
+--- com.android.tools.build:gradle:8.1.2 | --- com.android.tools.build:gradle:3.6.1 -> 8.1.2 () | +--- com.android.tools.build:gradle:7.0.4 -> 8.1.2 () | +--- com.android.tools.build:gradle:7.1.0 -> 8.1.2 (*)
Tasks executed
installRelease
Expected behavior
Using installRelease should be also possible when dev has not publishing keys set.