badge-plugin icon indicating copy to clipboard operation
badge-plugin copied to clipboard

version 2.0 is incompatible and breaks groovy-postbuild plugin

Open mawinter69 opened this issue 1 year ago • 5 comments

Jenkins and plugins versions report

Environment
Paste the output here

What Operating System are you using (both controller, and any agents involved in the problem)?

doesn't matter

Reproduction steps

https://github.com/jenkinsci/groovy-postbuild-plugin/blob/6eeecb7aeac5faa75313280ad67ad4c938e5bdc0/src/main/java/org/jvnet/hudson/plugins/groovypostbuild/GroovyPostbuildRecorder.java#L214 creates a new instance of BadgeSummaryAction I don't know the exact conditions when the code is called but it results in this stacktrace

[2024-09-18T03:04:30.919Z] java.lang.NoSuchMethodError: 'void com.jenkinsci.plugins.badge.action.BadgeSummaryAction.<init>(java.lang.String)'
[2024-09-18T03:04:30.919Z] 	at PluginClassLoader for groovy-postbuild//org.jvnet.hudson.plugins.groovypostbuild.GroovyPostbuildRecorder$BadgeManager.createSummary(GroovyPostbuildRecorder.java:214)
[2024-09-18T03:04:30.919Z] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2024-09-18T03:04:30.919Z] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

Expected Results

badge is properly created

Actual Results

build fails

Anything else?

No response

Are you interested in contributing a fix?

No response

mawinter69 avatar Sep 18 '24 10:09 mawinter69

My suggestion is to upgrade the groovy-postbuild-plugin in order to be compatible (I had that on my bucket list anyway). WDYT?

strangelookingnerd avatar Sep 18 '24 10:09 strangelookingnerd

definitely a solution

mawinter69 avatar Sep 18 '24 10:09 mawinter69

Once groovy-postbuild is adjusted I think the release notes should be updated to mention that groovy-postbuild must be updated as well

mawinter69 avatar Sep 18 '24 10:09 mawinter69

A pre-release of the groovy postbuild plugin is available for testing. Use the "Jenkins Incrementals Publisher" tab to access the most recent build.

MarkEWaite avatar Sep 25 '24 12:09 MarkEWaite

Thanks @MarkEWaite. The most recent build fixes the issue.

knapsu avatar Oct 02 '24 21:10 knapsu

Fixed in release 264.vf6e02a_77d5b_c of the groovy postbuild plugin.

strangelookingnerd avatar Oct 12 '24 22:10 strangelookingnerd