action-gh-release icon indicating copy to clipboard operation
action-gh-release copied to clipboard

Action tries to make a new release when one already exists

Open optix2000 opened this issue 3 years ago β€’ 5 comments

I use action-gh-release to automatically upload a CI build when a new release is cut. Recently this has stopped working. It looks like the action is trying to make the release, even though it already exists.

release:
    needs: build
    runs-on: ubuntu-latest
    if: ${{ github.event_name == 'release'}}
    permissions:
      contents: write
    steps:
    - uses: actions/download-artifact@v2
      with:
        name: totsugeki
    - uses: softprops/action-gh-release@v1
      with:
        files: totsugeki.exe

https://github.com/optix2000/totsugeki/runs/3275313508?check_suite_focus=true

Run softprops/action-gh-release@v1
πŸ‘©β€πŸ­ Creating new GitHub release for tag v1.1.3...
⚠️ GitHub release failed with status: 422, retrying... (2 retries remaining)
πŸ‘©β€πŸ­ Creating new GitHub release for tag v1.1.3...
⚠️ GitHub release failed with status: 422, retrying... (1 retries remaining)
πŸ‘©β€πŸ­ Creating new GitHub release for tag v1.1.3...
⚠️ GitHub release failed with status: 422, retrying... (0 retries remaining)
❌ Too many retries. Aborting...
Error: Too many retries.

Compared to previously: https://github.com/optix2000/totsugeki/runs/3268658767?check_suite_focus=true

Run softprops/action-gh-release@v1
⬆️ Uploading totsugeki.exe...
Deprecation: [@octokit/rest] "file" parameter is deprecated for ".repos.uploadReleaseAsset()". Use "data" instead
    at /home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:437047
    at Array.forEach (<anonymous>)
    at Object.s [as uploadReleaseAsset] (/home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:436958)
    at /home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:52043
    at Generator.next (<anonymous>)
    at /home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:50565
    at new Promise (<anonymous>)
    at i (/home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:50313)
    at Object.t.upload (/home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:51907)
    at /home/runner/work/_actions/softprops/action-gh-release/v1/dist/index.js:1:44485 {
  name: 'Deprecation'
}
πŸŽ‰ Release ready at https://github.com/optix2000/totsugeki/releases/tag/v1.1.2

optix2000 avatar Aug 08 '21 21:08 optix2000

I myself actually started getting this exact same thing this morning with no changes to how I was using this action.

CalvinWilkinson avatar Aug 08 '21 21:08 CalvinWilkinson

This is likely the same error reported in https://github.com/softprops/action-gh-release/issues/139

softprops avatar Aug 08 '21 23:08 softprops

Just saw this as well from https://github.com/kube-rs/kube-rs/issues/620 and I suspect it might have caused the interesting side-effect of inlining the body_path.txt file 3 times.

clux avatar Aug 09 '21 19:08 clux

caused the interesting side-effect of inlining the body_path.txt file 3 times.

I think I can see that regression in this pull request

https://github.com/softprops/action-gh-release/pull/109/files#diff-a248ff5ec76368168c745273fee0601b243545fdca37aa3bec76ef9e9365fdb7R189

Can you open a specific issue for that so that the info doesn’t get lost in the mix?

softprops avatar Aug 10 '21 02:08 softprops

the main issue the causing the error breaking releases is now fixed in https://github.com/softprops/action-gh-release/releases/tag/v0.1.12 (v1 tag was updated)

there may be smaller cosmetic issues but the main issue is resolved

softprops avatar Aug 10 '21 04:08 softprops