Gradle-play-publisher: Dry run mode

Created on 17 Dec 2020  路  4Comments  路  Source: Triple-T/gradle-play-publisher

Problem description

This is always a pain with the setup to market upload:

  1. You are afraid to break existing beauty
  2. The store is limiting upload by app version - so tedious to increment version all the time
  3. Usually it is done on CI and involving the secrets, so the number of possible mistakes and inconveniences is quadrupling

Potential solutions/workarounds

  1. I don't know if Google has this possibility in API but would be great to have something like a dry run
  2. Even if Google doesn't have it, the plugin can try not to upload apk and interpret the following error as a success, or so
enhancement other

Most helpful comment

I just realized there's a validate method which should solve #3: https://developers.google.com/android-publisher/api-ref/rest/v3/edits/validate.

All 4 comments

Well there's the Gradle dry run option that doesn't run any tasks, but I'm guessing that's not what you want.

GPP has the no commit option which will upload everything and then not publish it which I think is what you want. The one issue is that there are things which don't adhere to the edits api so the no commit option can't be used there (like in app products and internal app sharing for example).

Also of note is that validation tends to happen when you commit IIRC, so a dry run might not catch the errors you care about. Also, the only way you'll be able to check the changes is by calling the api yourself and looking at that pending edit (the play store won't show pending changes from the api).

Docs: https://github.com/Triple-T/gradle-play-publisher#combining-artifacts-into-a-single-release.
You probably just want to use --no-commit though since that explanation still publishes things.

API reference: https://developers.google.com/android-publisher/api-ref/rest.
Anything under edits can skip the commit.

Interesting! I did your plugin integration twice already and common issues were:

  1. The key is not correctly propagated from CI secrets/variables
  2. The credentials for a user that don't have correct rights
  3. Content of apk is invalid or something else wrong with the upload

So --no-commit will help at least with the first two.

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.

I just realized there's a validate method which should solve #3: https://developers.google.com/android-publisher/api-ref/rest/v3/edits/validate.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

aqibmumtaz picture aqibmumtaz  路  7Comments

SUPERCILEX picture SUPERCILEX  路  6Comments

lordcodes picture lordcodes  路  5Comments

siloebb picture siloebb  路  5Comments

chrisjenx picture chrisjenx  路  5Comments