-
Notifications
You must be signed in to change notification settings - Fork 56
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
Since 18.0.5 the plugin is now completely broken - Determination of nearest tag not working any longer for semver versions #250
Comments
Looking at the release notes: this should have been fixed with 7d369f6 (18.0.6) |
Unfortunately not. The plugin still infers the incorrect release version (0.0.1) but then checks this version against the latest semantic versioning tag. One part ist fixed, the other not. |
There's been a lot of refactoring to remove the JGit dependency, configuration cache compatibility, etc. Is this still an issue with the latest release? |
I should add, there's absolutely nothing wrong with sticking with a previous major release line, if you're having trouble accomodating recent changes, and FWIW we use the plugin in hundreds of thousands of builds per month. But do check the latest release when reporting bugs. |
Thanks for your reply, @DanielThomas ! |
If the git command works correctly on the system, the plugin will too. Let us know if it's still not working with the latest release. |
Hi @DanielThomas . I can see following lines in the Gitlab Runner's logs: |
Oh, I see the problem! We fixed a bug which caused numeric tags not prefixed with 'v' to be considered versions, and I bet you've been caught out by that. Add an adjacent tag to tag that latest release of v1.4.78 and inference should work again. |
But @rpalcolea that output still looks sus to me, do we still have a problem with tag filtering? |
Our release tags are all prefixed with "v". |
Ah, that's post parsing. Yeah, definitely seems odd. Let's see what Roberto says, I'm just guessing from recent commits I've seen fly by. |
We're just using the output of
nebula-release-plugin/src/main/groovy/nebula/plugin/release/git/command/GitReadCommand.groovy Lines 106 to 118 in 6eaf9a5
The documentation for
https://git-scm.com/docs/git-describe#_search_strategy Which is a departure from the previous JGit. Could you have a mix of lightweight and annotated commits for versions? Unlikely to be detached commits, you get the nearest commit suffixed with the distance and abbreviated sha:
Which it looks like we're accomodating fine in nebula-release-plugin/src/main/groovy/nebula/plugin/release/git/semver/NearestVersionLocator.groovy Lines 91 to 102 in 6eaf9a5
Check for annotated version tags, and check for |
Oh damn. I think I found the cause of the problem. The "curated" executor image provided by our infrastructure team has git 1.8 on board which does not support the exclude option with describe. Locally I am using an up to date git installation. That's why everything is fine locally. Well, I think I have to have a chat with our infrastructure team and bump git's version a bit. Thanks for all your help and pushing me in the right direction! I will report back once I have a current git version in usage. |
Aha! You're welcome, definitely not the easiest to track down if you don't know where to look. Hey @rpalcolea, we might want to add a minimum version check for git, and we might not be handling an exit code correctly too. |
We have been a long time user of the nebula-release-plugin but starting with the refactoring since the 18.0.0 version the plugin is getting more and more unstable.
Things that have been working for years now aren't working any longer.
With version 18.0.5 the plugin is not able to find version tags any longer and defaults to UNKNOWN = Version.valueOf('0.0.0').
The issues section seems to be dead since no developer has reacted to any issue since June.
For the time being we pinned the plugin's version in Renovate. Quite sad, but in the mid term we seem to have to move to another plugin for semver releasing.
The text was updated successfully, but these errors were encountered: