Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot find GoReleaser latest version #389

Closed
till opened this issue Jan 27, 2023 · 18 comments · Fixed by #390
Closed

cannot find GoReleaser latest version #389

till opened this issue Jan 27, 2023 · 18 comments · Fixed by #390

Comments

@till
Copy link

till commented Jan 27, 2023

This randomly happened just now:

  check:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Set up Go
        uses: actions/setup-go@v3
        with:
          go-version: 1.16
      - name: Run GoReleaser
        uses: goreleaser/goreleaser-action@v4
        with:
          version: latest
          args: release --snapshot --rm-dist
      - name: Run Tests
        run: go test -v ./...
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Error message:

  Run goreleaser/goreleaser-action@v4
  with:
    args: build --snapshot --single-target --rm-dist
    distribution: goreleaser
    version: latest
    workdir: .
    install-only: false
  env:
    GOPRIVATE: github.com/org/repo
    DOWNLOAD_PACKAGE_TOKEN: ***
    GITHUB_TOKEN: ***
Error: Cannot find GoReleaser latest release
@graytonio
Copy link

I just had the same issue

@graytonio
Copy link

Trying to fix to a version also appears broken

- uses: goreleaser/goreleaser-action@v4
    with:
      distribution: goreleaser
      version: v1.14.1
      args: release --rm-dist
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
    distribution: goreleaser
    version: v1.1[4](https://github.com/graytonio/zoltan-bot/actions/runs/4029061823/jobs/6926570684#step:6:4).1
    args: release --rm-dist
    workdir: .
    install-only: false
  env:
    GITHUB_TOKEN: ***
  
Error: Cannot find GoReleaser v1.14.1 release

@crazy-max
Copy link
Member

We have the same issue in docker/setup-buildx-action#190, GitHub API looks broken 😞

@caarlos0
Copy link
Member

in this particular case, I think we could use https://goreleaser.com/static/latest instead... will see if I can fix it real quick

@caarlos0
Copy link
Member

oh, but we do actually get the "biggest" version number from https://goreleaser.com/static/releases.json , so maybe its downloading from github that was failing?

@caarlos0
Copy link
Member

Error: Cannot find GoReleaser v1.14.1 release

yeah looks like

@caarlos0
Copy link
Member

def something on github, action tests were passing up to 15h ago (the failures are because I rotated a key and forgot to change here, just fixed it)... and now they don't pass anymore...

@caarlos0
Copy link
Member

we're going to do this: docker/setup-buildx-action#191

it seems that github stopped supporting the url we were using to get the releases...

@budnieswski
Copy link

@caarlos0

It could be something related to the URL to get the release...

What do you think of replacing
this:
https://github.com/goreleaser/${distribution}/releases/${resolvedVersion}
by this?:
https://api.github.com/repos/goreleaser/${distribution}/releases/${resolvedVersion}

do a get on this URL (https://api.github.com/repos/goreleaser/goreleaser/releases/latest), it brings the right list of assets

@caarlos0
Copy link
Member

btw, wanna leave here public BIG thanks to @crazy-max for getting on top of it 💙

@caarlos0
Copy link
Member

@budnieswski yes, that URL worked before though..., they just broke it it seems :|

@wcmjunior
Copy link

@caarlos0 , seems like the fix proposed in docker/setup-buildx-action#191 brings some implications for GH enterprise. Just a heads up in case you are not following the thread in real time. :)

@ldemailly
Copy link

ldemailly commented Jan 28, 2023

Same issue here. Also I'm a bit puzzled at what is the point of me pinning the SHA of the action (and reviewing dependabot updates as needed) but then not getting reproducible builds?

edit: Sorry for jumping the gun initially, that's on me for leaving

          version: latest

in the action config itself and I guess noone's fault if the URL disappeared (well, github's maybe) - thanks in advance for the quick fixes

@crazy-max
Copy link
Member

@wcmjunior Should be sorted with docker/setup-buildx-action#192

We are going to do the same here

@caarlos0
Copy link
Member

ight me and @crazy-max got #390 ready (probably)

@caarlos0
Copy link
Member

okay just released https://github.com/goreleaser/goreleaser-action/releases/tag/v4.1.1

@caarlos0
Copy link
Member

successfully run a release just now: https://github.com/caarlos0/goreleaser-action-v4-auto-snapshot-example/actions/runs/4029341069/jobs/6927878915

@till
Copy link
Author

till commented Jan 28, 2023

Thanks so much for taking care of it so fast. 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants