goreleaser / goreleaser-action

GitHub Action for GoReleaser
https://github.com/marketplace/actions/goreleaser-action
MIT License
833 stars 73 forks source link

Release Failure with Official Versions using GoReleaser Action v4 #445

Closed cubxxw closed 6 months ago

cubxxw commented 6 months ago

I'm encountering an issue with GoReleaser Action v4 when releasing different types of versions. Pre-releases like v3.5.1.beta.0 are successfully published, but official releases (e.g., v3.5.1) fail.

Error encountered:

"failed to upload artifact... error=POST https://uploads.github.com/repos/***sdk/chat/releases/135400526/assets?name=chat_1.5.1-rc.0_linux_ppc64le.pkg.tar.zst: 422 Validation Failed [{Resource:ReleaseAsset Field:name Code:already_exists Message:}]"

Complete error log available at: https://github.com/openimsdk/chat/actions/runs/7364259821/job/20044473138

It seems like there's an issue with asset uploading for official releases. Pre-release assets upload without problems. Any insights or solutions would be greatly appreciated.

Thanks!

cubxxw commented 6 months ago

@crazy-max

caarlos0 commented 6 months ago

You are likely running the release two times concurrently when a tag is created

caarlos0 commented 6 months ago

Oh, my bad, it's something with tag sorting, it tried to release rc0 again

Changing git.tag_sort should help

https://goreleaser.com/customization/git/

cubxxw commented 6 months ago

Certainly, thank you for your assistance. I will now proceed to give it a try.