-
Notifications
You must be signed in to change notification settings - Fork 31
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
[JENKINS-73781] Make plugin compatible with git client 5.0.0 and 6.0.0 #97
[JENKINS-73781] Make plugin compatible with git client 5.0.0 and 6.0.0 #97
Conversation
peel()
with getRefDatabase().peel()
peel()
with getRefDatabase().peel()
@rmpestano this needs to be merged and released so that users who install Jenkins 2.463 or later do not see a last changes plugin regression due to the JGit 7.0.0 changes that are included in Git client plugin 6.0.0 and later. The changes are compatible with earlier versions of the git client plugin as well, so should be very low risk for users. Are you available to merge and release it? |
Assembla now requires authenticated access for their Subversion repositories. The shouldGetLastChangesFromLatestTag test already used this same technique to only run the test when the PASS system property is provided. Make shouldGetLastChanges the same as shouldGetLastChangesFromLatestTag. Test fails on the master branch as well. This change ignores shouldGetLastChanges on ci.jenkins.io in the same way that shouldGetLastChangesFromLatestTag was already ignored.
https://issues.jenkins.io/browse/JENKINS-73781 notes that JGit deprecated peel() in favor of getRefDatabase().peel() a long time ago. The deprecated method was removed from JGit 7.0.0. This uses the replacement method that has been available since the deprecation. jenkinsci/git-client-plugin#1170 is the git client plugin pull request that introduced JGit 7.0.0. https://github.com/jenkinsci/git-client-plugin/releases/tag/git-client-6.0.0 is the git client plugin release that introduced JGit 7.0.0.
c8a881d
to
4271d1a
Compare
jenkinsci/last-changes-plugin#97 needs to be merged and released so that users of the last-changes plugin are not disrupted when they upgrade to git client 5.0.0 or git client plugin 6.0.0. $The pull request was submitted in September. There has been no response from @rmpestano. jenkinsci/last-changes-plugin#97 (comment) That pull request is a minimal change that adapts to git client plugin 5.0.0 and later without unnecessary changes. Other changes to modernize the plugin can be considered once the immediate issue with newer versions of git client plugin has been resolved. jenkinsci/last-changes-plugin#98 includes several steps to modernize the plugin, though it has not been tested yet.
@MarkEWaite thanks for stepping in, are you able to release? I don't think I have the maven setup to do that anymore |
I'm not yet able to release, but will be able to release very soon, once the processing is completed from the merged pull request: |
[JENKINS-73781] Make plugin compatible with git client 5.0.0 and 6.0.0
Replaces JGit
peel()
withgetRefDatabase().peel()
JENKINS-73781 notes that JGit deprecated
peel()
in favor ofgetRefDatabase().peel()
a long time ago. The deprecated method was removed from JGit 7.0.0. This uses the replacement method that has been available since the deprecation. This change works with both the older JGit versions (6.x) and the most recent JGit 7.0.0 release.The git client plugin pull request that introduced JGit 7.0.0 is:
Git client plugin 6.0.0 is the git client plugin release that introduced JGit 7.0.0.
The test that is failing on the master branch has been updated to use the same pattern as another test in the same file. Assembla now requires authenticated access for their Subversion repositories. The
shouldGetLastChangesFromLatestTag
test already used this same technique to only run the test when the PASS system property is provided. MakeshouldGetLastChanges
the same asshouldGetLastChangesFromLatestTag
.This change ignores
shouldGetLastChanges
on ci.jenkins.io in the same way thatshouldGetLastChangesFromLatestTag
was already ignored, since thePASS
property is not set on ci.jenkins.io.Testing done
Automated tests pass. No interactive testing has been performed because the changes are minor. The same change was applied to the git client plugin when it transitioned from JGit 6.10.0 to JGit 7.0.0 and all tests were passing with git client plugin.
Submitter checklist