Closed norrisjeremy closed 2 months ago
Thanks for reporting.
Since the integration tests are green, could you provide some more context? Or even better reproduce this in the tests?
Hi @tcurdt,
Sorry, I didn't see your response last week.
The issue seems to occur if the pom.xml contains a <project.build.outputTimestamp>
property.
For example, if I make this simple change, then the integration tests start to fail:
diff --git a/src/it/pom-only/pom.xml b/src/it/pom-only/pom.xml
index bb67fd7..388ad3f 100644
--- a/src/it/pom-only/pom.xml
+++ b/src/it/pom-only/pom.xml
@@ -11,6 +11,7 @@
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
+ <project.build.outputTimestamp>2024-08-26T14:00:00Z</project.build.outputTimestamp>
</properties>
<build>
<plugins>
Thanks, Jeremy
Thanks for making this reproducible.
[INFO] Building: pom-only/pom.xml
[INFO] [INFO] Error stacktraces are turned on.
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
[INFO] [INFO] -------------------------< org.vafer:jdeb-it >--------------------------
[INFO] [INFO] Building jdeb-it 1.0
[INFO] [INFO] from pom.xml
[INFO] [INFO] --------------------------------[ pom ]---------------------------------
[INFO] [INFO]
[INFO] [INFO] --- clean:3.2.0:clean (default-clean) @ jdeb-it ---
[INFO] [INFO]
[INFO] [INFO] --- prefix:1.11:jdeb (default) @ jdeb-it ---
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] BUILD FAILURE
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] Total time: 0.289 s
[INFO] [INFO] Finished at: 2024-08-26T16:38:03+02:00
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [ERROR] Failed to execute goal org.vafer:jdeb:1.11:jdeb (default) on project jdeb-it: Execution default of goal org.vafer:jdeb:1.11:jdeb failed: A required class was missing while executing org.vafer:jdeb:1.11:jdeb: org/apache/maven/archiver/MavenArchiver
[INFO] [ERROR] -----------------------------------------------------
[INFO] [ERROR] realm = plugin>org.vafer:jdeb:1.11
[INFO] [ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[INFO] [ERROR] urls[0] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/vafer/jdeb/1.11/jdeb-1.11.jar
[INFO] [ERROR] urls[1] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant/1.10.14/ant-1.10.14.jar
[INFO] [ERROR] urls[2] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant-launcher/1.10.14/ant-launcher-1.10.14.jar
[INFO] [ERROR] urls[3] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-sec-dispatcher/1.4/plexus-sec-dispatcher-1.4.jar
[INFO] [ERROR] urls[4] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/codehaus/plexus/plexus-utils/1.5.5/plexus-utils-1.5.5.jar
[INFO] [ERROR] urls[5] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[INFO] [ERROR] Number of foreign imports: 1
[INFO] [ERROR] import: Entry[import from realm ClassRealm[maven.api, parent: null]]
[INFO] [ERROR]
[INFO] [ERROR] -----------------------------------------------------: org.apache.maven.archiver.MavenArchiver
[INFO] [ERROR] -> [Help 1]
[INFO] org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.vafer:jdeb:1.11:jdeb (default) on project jdeb-it: Execution default of goal org.vafer:jdeb:1.11:jdeb failed: A required class was missing while executing org.vafer:jdeb:1.11:jdeb: org/apache/maven/archiver/MavenArchiver
[INFO] -----------------------------------------------------
[INFO] realm = plugin>org.vafer:jdeb:1.11
[INFO] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[INFO] urls[0] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/vafer/jdeb/1.11/jdeb-1.11.jar
[INFO] urls[1] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant/1.10.14/ant-1.10.14.jar
[INFO] urls[2] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant-launcher/1.10.14/ant-launcher-1.10.14.jar
[INFO] urls[3] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-sec-dispatcher/1.4/plexus-sec-dispatcher-1.4.jar
[INFO] urls[4] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/codehaus/plexus/plexus-utils/1.5.5/plexus-utils-1.5.5.jar
[INFO] urls[5] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[INFO] Number of foreign imports: 1
[INFO] import: Entry[import from realm ClassRealm[maven.api, parent: null]]
[INFO]
[INFO] -----------------------------------------------------
[INFO]
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:333)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
[INFO] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
[INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
[INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
[INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
[INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
[INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
[INFO] at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
[INFO] at java.lang.reflect.Method.invoke (Method.java:580)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[INFO] Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default of goal org.vafer:jdeb:1.11:jdeb failed: A required class was missing while executing org.vafer:jdeb:1.11:jdeb: org/apache/maven/archiver/MavenArchiver
[INFO] -----------------------------------------------------
[INFO] realm = plugin>org.vafer:jdeb:1.11
[INFO] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[INFO] urls[0] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/vafer/jdeb/1.11/jdeb-1.11.jar
[INFO] urls[1] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant/1.10.14/ant-1.10.14.jar
[INFO] urls[2] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant-launcher/1.10.14/ant-launcher-1.10.14.jar
[INFO] urls[3] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-sec-dispatcher/1.4/plexus-sec-dispatcher-1.4.jar
[INFO] urls[4] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/codehaus/plexus/plexus-utils/1.5.5/plexus-utils-1.5.5.jar
[INFO] urls[5] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[INFO] Number of foreign imports: 1
[INFO] import: Entry[import from realm ClassRealm[maven.api, parent: null]]
[INFO]
[INFO] -----------------------------------------------------
[INFO]
[INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:152)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
[INFO] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
[INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
[INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
[INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
[INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
[INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
[INFO] at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
[INFO] at java.lang.reflect.Method.invoke (Method.java:580)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[INFO] Caused by: org.apache.maven.plugin.PluginContainerException: A required class was missing while executing org.vafer:jdeb:1.11:jdeb: org/apache/maven/archiver/MavenArchiver
[INFO] -----------------------------------------------------
[INFO] realm = plugin>org.vafer:jdeb:1.11
[INFO] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[INFO] urls[0] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/vafer/jdeb/1.11/jdeb-1.11.jar
[INFO] urls[1] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant/1.10.14/ant-1.10.14.jar
[INFO] urls[2] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/apache/ant/ant-launcher/1.10.14/ant-launcher-1.10.14.jar
[INFO] urls[3] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-sec-dispatcher/1.4/plexus-sec-dispatcher-1.4.jar
[INFO] urls[4] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/codehaus/plexus/plexus-utils/1.5.5/plexus-utils-1.5.5.jar
[INFO] urls[5] = file:/Users/tcurdt/Projects/jdeb/target/local-repo/org/sonatype/plexus/plexus-cipher/1.4/plexus-cipher-1.4.jar
[INFO] Number of foreign imports: 1
[INFO] import: Entry[import from realm ClassRealm[maven.api, parent: null]]
[INFO]
[INFO] -----------------------------------------------------
[INFO]
[INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:150)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
[INFO] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
[INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
[INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
[INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
[INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
[INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
[INFO] at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
[INFO] at java.lang.reflect.Method.invoke (Method.java:580)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[INFO] Caused by: java.lang.NoClassDefFoundError: org/apache/maven/archiver/MavenArchiver
[INFO] at org.vafer.jdeb.utils.OutputTimestampResolver.resolveOutputTimestamp (OutputTimestampResolver.java:24)
[INFO] at org.vafer.jdeb.maven.DebMojo.execute (DebMojo.java:597)
[INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:126)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
[INFO] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
[INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
[INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
[INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
[INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
[INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
[INFO] at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
[INFO] at java.lang.reflect.Method.invoke (Method.java:580)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[INFO] Caused by: java.lang.ClassNotFoundException: org.apache.maven.archiver.MavenArchiver
[INFO] at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass (SelfFirstStrategy.java:42)
[INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass (ClassRealm.java:225)
[INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass (ClassRealm.java:210)
[INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass (ClassRealm.java:205)
[INFO] at org.vafer.jdeb.utils.OutputTimestampResolver.resolveOutputTimestamp (OutputTimestampResolver.java:24)
[INFO] at org.vafer.jdeb.maven.DebMojo.execute (DebMojo.java:597)
[INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:126)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
[INFO] at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
[INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
[INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
[INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
[INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
[INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
[INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
[INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
[INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
[INFO] at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
[INFO] at java.lang.reflect.Method.invoke (Method.java:580)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:255)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:201)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:361)
[INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:314)
[INFO] [ERROR]
[INFO] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[INFO] [ERROR]
[INFO] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[INFO] [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginContainerException
[INFO] The build exited with code 1. See /Users/tcurdt/Projects/jdeb/target/it/pom-only/build.log for details.
[INFO] pom-only/pom.xml ................................. FAILED (1.279 s)
Seems it missing org/apache/maven/archiver/MavenArchiver
.
I've gave it a try without a <minimizeJar>true</minimizeJar>
but it still fails.
Not sure where that dependency is coming from yet.
Hi @tcurdt,
I think the problem is that you are declaring the maven-archiver
dependency as provided
scope.
Thanks, Jeremy
Hi @tcurdt,
With this change, integration tests pass:
diff --git a/pom.xml b/pom.xml
index 1ebe2a2..05e62a8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -125,7 +125,6 @@
<groupId>org.apache.maven</groupId>
<artifactId>maven-archiver</artifactId>
<version>3.6.2</version>
- <scope>${maven.scope}</scope>
</dependency>
<dependency>
<groupId>org.apache.ant</groupId>
diff --git a/src/it/pom-only/pom.xml b/src/it/pom-only/pom.xml
index bb67fd7..388ad3f 100644
--- a/src/it/pom-only/pom.xml
+++ b/src/it/pom-only/pom.xml
@@ -11,6 +11,7 @@
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
+ <project.build.outputTimestamp>2024-08-26T14:00:00Z</project.build.outputTimestamp>
</properties>
<build>
<plugins>
Thanks, Jeremy
And for reference, you can see other projects, like maven-jar-plugin
do not declare maven-archiver
with provided
scope, see https://github.com/apache/maven-jar-plugin/blob/5c461dc64b6379f46edf09bb73302937d5ef6981/pom.xml#L129.
Good thinking. So, can you confirm it fixes your build by providing that dependency from your pom?
Given that jdeb
is for ant
and maven
it feels not quite right making it a required dependency.
I need to stew on that a bit.
Hi @tcurdt,
Yes, manually adding it as a dependency like this fixes the build:
<plugin>
<groupId>org.vafer</groupId>
<artifactId>jdeb</artifactId>
<version>1.11</version>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-archiver</artifactId>
<version>3.6.2</version>
</dependency>
</dependencies>
<executions>
...
</executions>
</plugin>
Thanks, Jeremy
Also, I'm not sure I understand the consternation behind just declaring the dependency with the correct scope?
The maven-archiver
artifact is not a part of the core Maven API that is de-facto provided
by Maven, so it has to declared as a non-provided dependency in order to utilize it.
jdeb
is not split into jdeb-core
, jdeb-ant
and jdeb-maven
which means adding build platform specific dependencies is a penalty for some users. Hence I am trying to be as conservative with dependencies as possible.
I guess the right thing would be split the project. Adding the dep is probably still the 2nd best option.
Hi @tcurdt,
But previous releases prior to 1.11 already had a dependency on maven-archiver
, so would you consider reintroducing the dependency in a 1.11.1 interim release in order to remove the newly introduced regression, while you consider how to split the components?
Thanks, Jeremy
Ah, gotcha. Sounds like a regression during the cleanup and upgrades.
Since you tracked this down - want to create a PR to get the credit?
Hi @tcurdt,
See #744.
Thanks, Jeremy
Hi @tcurdt,
Will you publish a new release to Maven Central with this regression fix?
Thanks, Jeremy
Might take a few days but I will.
Hi @tcurdt,
See #745 for more improvements to the prior change.
I discovered that maven-invoker-plugin
wasn't actually executing the verify scripts for the integration tests.
Additionally I added verification that that the resulting .deb
file correctly sets the last modified timestamp of it's entries to the project.build.outputTimestamp
value.
Thanks, Jeremy
We are seeing the following Maven errors when attempting to use the new 1.11 release: