xresloader / upload-to-github-release

MIT License
52 stars 10 forks source link

Error while uploading: already_exists with overwrite true #18

Closed patrickelectric closed 2 years ago

patrickelectric commented 3 years ago

I'm having the following error message:

Upload asset: pingviewer-Release.dmg failed => Validation Failed: {"resource":"ReleaseAsset","code":"already_exists","field":"name"} HttpError: Validation Failed: {"resource":"ReleaseAsset","code":"already_exists","field":"name"}     at /Users/runner/work/_actions/xresloader/upload-to-github-release/v1/lib/index.js:13125:23     at processTicksAndRejections (internal/process/task_queues.js:93:5)

Configuration:

    - name: Update continuous release
      uses: xresloader/upload-to-github-release@v1
      if: ${{ github.event_name != 'pull_request' }}
      env:
        GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
      with:
        tag_name: continuous
        file: ${{ matrix.DEPLOY_PATH }}
        tags: false
        draft: false
        overwrite: true
        prerelease: true
        verbose: true
owent commented 3 years ago

@patrickelectric Could you provide the log? When setting overwrite: true , this action will try to remove the old file and then upload the new one. If another job upload pingviewer-Release.dmg between the removing and the uploading operations, this will happen. It's recommended to set max-parallel: 1 to your uploading job.

patrickelectric commented 3 years ago

https://github.com/bluerobotics/ping-viewer/runs/2277562697?check_suite_focus=true I just restarted it and I was able to replicate, and as you can see from the others jobs, no job have reached the upload step with the mac build.

patrickelectric commented 3 years ago

Also failed with max-parallel: 1 https://github.com/bluerobotics/ping-viewer/runs/2278292920?check_suite_focus=true

owent commented 3 years ago

Thanks for your report.The problem is the old file pingviewer-release.dmg has the different case with the new one(pingviewer-Release.dmg). The v1.3.1 should fix this problem, please retry the job later.