github-tag-action: Major bump not working as before since 1.29.0

We use this action to create a new major version on every merge to master, but since 1.29.0 it keep trying to create the a most recently used tag, in this case 662.0.0.

We’ve reverted to 1.28.0 and it’s working ok again so not sure what changed.

... omitted ...
2020-09-15T17:10:59.2448813Z  * [new tag]           662.0.0                 -> 662.0.0
2020-09-15T17:10:59.2449371Z  * [new tag]           67.0.0                  -> 67.0.0
2020-09-15T17:10:59.2449931Z  * [new tag]           68.0.0                  -> 68.0.0
2020-09-15T17:10:59.2450495Z  * [new tag]           69.0.0                  -> 69.0.0
2020-09-15T17:10:59.2451051Z  * [new tag]           7.0.0                   -> 7.0.0
2020-09-15T17:10:59.2451610Z  * [new tag]           70.0.0                  -> 70.0.0
2020-09-15T17:10:59.2452196Z  * [new tag]           70.100.1                -> 70.100.1
2020-09-15T17:10:59.2452763Z  * [new tag]           70.100.2                -> 70.100.2
2020-09-15T17:10:59.2453349Z  * [new tag]           70.101.1                -> 70.101.1
2020-09-15T17:10:59.2453917Z  * [new tag]           70.101.2                -> 70.101.2
2020-09-15T17:10:59.2454485Z  * [new tag]           70.99.1                 -> 70.99.1
... omitted ...
2020-09-15T17:10:59.2489855Z  * [new tag]           97.0.0                  -> 97.0.0
2020-09-15T17:10:59.2490442Z  * [new tag]           97.114.6                -> 97.114.6
2020-09-15T17:10:59.2491011Z  * [new tag]           97.114.7                -> 97.114.7
2020-09-15T17:10:59.2491578Z  * [new tag]           97.118.3                -> 97.118.3
2020-09-15T17:10:59.2492151Z  * [new tag]           97.118.4                -> 97.118.4
2020-09-15T17:10:59.2492720Z  * [new tag]           97.118.5                -> 97.118.5
2020-09-15T17:10:59.2493288Z  * [new tag]           97.118.6                -> 97.118.6
2020-09-15T17:10:59.2494435Z  * [new tag]           97.119.1                -> 97.119.1
2020-09-15T17:10:59.2495032Z  * [new tag]           98.0.0                  -> 98.0.0
2020-09-15T17:10:59.2495596Z  * [new tag]           99.0.0                  -> 99.0.0
2020-09-15T17:10:59.2496508Z  * [new tag]           99.119.2                -> 99.119.2
2020-09-15T17:10:59.2496956Z Trigger build
2020-09-15T17:10:59.3455660Z major
2020-09-15T17:10:59.3456024Z 662.0.0
2020-09-15T17:10:59.3497649Z fatal: tag '662.0.0' already exists
2020-09-15T17:10:59.3889592Z 2020-09-15T17:10:59Z: **pushing tag 662.0.0 to repo echo-health/prescriptions
2020-09-15T17:10:59.8752362Z   "message": "Reference already exists",
2020-09-15T17:10:59.8755460Z   "documentation_url": "https://docs.github.com/rest/reference/git#create-a-reference"
2020-09-15T17:10:59.8756893Z }

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 24 (12 by maintainers)

Most upvoted comments

Thanks, I’m going to revert 1.45.0 for a number of reasons, but will try to have a look at this at some point but it might not be until next week.

@sammcj here is the related parts, rest of them are omitted:

  tag:
    runs-on: ubuntu-latest
    needs:
      - codeql
      - sonarcloud
      - build
    steps:
      - name: Checkout
        uses: actions/checkout@v3
        with:
          fetch-depth: '0'
      - name: Bump version and push tag
        uses: anothrNick/github-tag-action@1.45.0
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          WITH_V: true
          DEFAULT_BUMP: patch

  release:
    runs-on: ubuntu-latest
    needs:
      - tag
    steps:
      - name: Checkout
        uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Set outputs
        id: vars
        run: |
          echo "::set-output name=latest_tag::$(git describe --tags $(git rev-list --tags --max-count=1))"
          echo "::set-output name=build_time::$(date -u +'%m-%d-%YT%H:%M:%SZ')"
          echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
      - name: Set up QEMU
        uses: docker/setup-qemu-action@v2
      - name: Docker Login
        uses: docker/login-action@v2
        with:
          registry: docker.io
          username: ${{ github.repository_owner }}
          password: ${{ secrets.DOCKER_PASSWORD }}
      - name: Install Go
        uses: actions/setup-go@v3
        with:
          go-version-file: "go.mod"
      - name: Run GoReleaser
        uses: goreleaser/goreleaser-action@v2
        with:
          version: latest
          args: release --rm-dist --config build/package/.goreleaser.yaml
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          TAP_GITHUB_TOKEN: ${{ secrets.TAP_GITHUB_TOKEN }}

Merged #89. Logging should be available from 1.30.0