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

Occasionally gives the wrong version #13

Open
wdoug opened this issue Mar 4, 2021 · 5 comments · May be fixed by #32
Open

Occasionally gives the wrong version #13

wdoug opened this issue Mar 4, 2021 · 5 comments · May be fixed by #32
Labels
bug Something isn't working

Comments

@wdoug
Copy link

wdoug commented Mar 4, 2021

What happened

Sometimes this gives me the wrong version. I'm not sure why. For example, see the output of this workflow. The latest tag should be 2.9.0, but this action is repeatedly giving 2.8.1 as the latest (which was also created earlier).

Screen Shot 2021-03-03 at 9 23 46 PM

What you expected to happen

I expected that I would get the highest release for the repo by default.

How to reproduce it

I'm not sure

@wdoug wdoug added the bug Something isn't working label Mar 4, 2021
@wdoug
Copy link
Author

wdoug commented Mar 4, 2021

Oh, hmm. I'm realizing that somehow I ended up tagging that same commit twice...
Screen Shot 2021-03-03 at 9 37 08 PM

I would still have hoped this GitHub action would have gotten the latest SemVer tag

@wdoug
Copy link
Author

wdoug commented Aug 23, 2021

Okay, this just happened again and this time the commits are definitely different.
Screen Shot 2021-08-23 at 4 31 45 PM
Screen Shot 2021-08-23 at 4 33 13 PM

Screen Shot 2021-08-23 at 4 34 34 PM
Screen Shot 2021-08-23 at 4 34 41 PM

@wdoug
Copy link
Author

wdoug commented Aug 24, 2021

Okay, for our purposes it looks like setting semver_only to true resolved that second issue.

@Graicc
Copy link

Graicc commented Nov 30, 2021

I had the same issue with the wrong tag being selected when multiple tags were on one commit, fixed it by running echo "::set-output name=a::$(git tag --sort=v:refname | tail -n 1)" instead of using this action. e.g.

- name: Get Lastest Tag
  id: get-latest-tag
  run: echo "::set-output name=tag::$(git tag --sort=v:refname | tail -n 1)"

@Kuhpik
Copy link

Kuhpik commented May 3, 2022

Same bug here.
Latest tag was 1.2.5 but this action takes 1.2.3 which was made like months ago. I think it happens when you use actions from branches other than main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants