taiki-e / upload-rust-binary-action

GitHub Action for building and uploading Rust binary to GitHub Releases.
Apache License 2.0
247 stars 22 forks source link

Retry 500 errors from `gh release` #52

Closed Veetaha closed 1 year ago

Veetaha commented 1 year ago

See this example release run: ci link. Upload failed with the following output.

+ gh release upload v0.3.0 cargo-marker-x86_64-unknown-linux-gnu.tar.gz cargo-marker-x86_64-unknown-linux-gnu.zip cargo-marker-x86_64-unknown-linux-gnu.sha256 --clobber
HTTP 502: Server Error (https://api.github.com/repos/Veetaha/marker/releases/assets/125294025)
Error: Process completed with exit code 1.

I suggest using exponential backoff to retry the gh release operation when it fails. Here is an example bash function that we use to retry any network operations.

taiki-e commented 1 year ago

Thanks for the report! Addressed in 1.16.1.