oliviergauthier / gradle-appcenter-plugin

This gradle plugin allow you to upload each build variant of your android application to separate AppCenter Apps.
MIT License
85 stars 45 forks source link

AppCenterUploaderException 1.3.0 #81

Closed Taost closed 2 years ago

Taost commented 2 years ago

We are seeing intermittent failures to upload APKs to appcenter. Recently it happens much more often. It seems the failure falls to this line of the plugin. https://github.com/oliviergauthier/gradle-appcenter-plugin/blob/master/src/main/kotlin/com/betomorrow/gradle/appcenter/infra/AppCenterUploader.kt#L74

* What went wrong:
11:01:37  Execution failed for task ':xxx:appCenterUploadApkxxx'.
11:01:37  > com.betomorrow.gradle.appcenter.infra.AppCenterUploaderException: Fetching release id failed: Tried 60 times.

We are running plugin version 1.3.0. Please let us know if you have any suggestion. Thanks!

Rolf-Smit commented 2 years ago

I see the same thing, it happens way more often. The https://status.appcenter.ms/ page shows no issues, however I'm pretty sure this is an AppCenter server issue. Lately I have grown more and more unsatisfied with the service, due to issues like this.

TLDR: I doubt something can be done about this in this Gradle Plugin.

Rolf-Smit commented 2 years ago

Got me thinking, should we increase the timeout between trying to get the upload? Maybe 1 second times 60, is just one minute, maybe that is too fast?

Taost commented 2 years ago

Our iOS team, who uses App Center fastlane plugin, has more stable uploading experience. Looking at the fastlane plugin code, it seems they don't have the max retries limit. Maybe that is something we can try here? https://github.com/microsoft/fastlane-plugin-appcenter/blob/2b8aef1aa9a75faf09f14428d50d65d9d35b34e7/lib/fastlane/plugin/appcenter/helper/appcenter_helper.rb#L441

Rolf-Smit commented 2 years ago

@Taost my Pull-request is based on the official AppCenter CLI, which also works without a limit.

However waiting forever felt a bit extreme. Instead it waits for 15 minutes (Instead of 60 seconds or forever), I feel like that is more than enough for a CI task.

Taost commented 2 years ago

@Rolf-Smit Thanks for working on this! The PR looks good! Hope it will be merged in soon.

Rolf-Smit commented 2 years ago

@oliviergauthier are you seeing this? Last year I created a fork of this project because I deemed it to be "inactive". Then suddenly the project became active again (so I archived my fork), but now it seems to be stalled once more.

If you are having troubles to support this project on your own I'm willing to help out where I can. Please let us know what you need.