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

Make dep on matrix-project optional #234

Merged
merged 1 commit into from
Jul 18, 2024

Conversation

jglick
Copy link
Member

@jglick jglick commented Jul 18, 2024

@jglick jglick requested a review from a team as a code owner July 18, 2024 13:14
@jglick jglick added the enhancement New feature or improvement label Jul 18, 2024
Comment on lines +78 to +83
<exclusions>
<exclusion>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>gradle</artifactId>
</exclusion>
</exclusions>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines -546 to +550
} else if (src instanceof MatrixBuild) {
} else if (jenkins.getPlugin("matrix-project") != null && src instanceof MatrixBuild) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compare #14 (amending 4fd5c3e). Without this, the new test fails:

Started
[Pipeline] Start of Pipeline
[Pipeline] node
Running on Jenkins in …/copyartifact-plugin/target/tmp/j h11474560698679713783/workspace/downstream
[Pipeline] {
[Pipeline] copyArtifacts
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
java.lang.ClassNotFoundException: hudson.matrix.MatrixBuild
	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:445)
	at jenkins.util.URLClassLoader2.findClass(URLClassLoader2.java:35)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:592)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
Also:   org.jenkinsci.plugins.workflow.actions.ErrorAction$ErrorId: af406f0c-e047-466c-874b-a56e04bfb18a
Caused: java.lang.NoClassDefFoundError: hudson/matrix/MatrixBuild
	at hudson.plugins.copyartifact.CopyArtifact.perform(CopyArtifact.java:546)
	at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
	at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:101)
	at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:71)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.lang.Thread.run(Thread.java:840)
Finished: FAILURE

@jglick
Copy link
Member Author

jglick commented Jul 18, 2024

I seem to have write permissions here, though I am not in the dev group…should probably be fixed.

Copy link
Contributor

@mPokornyETM mPokornyETM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mPokornyETM mPokornyETM merged commit fbdcaa9 into jenkinsci:master Jul 18, 2024
16 checks passed
@jglick jglick deleted the matrix-project branch July 18, 2024 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants