You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by gn...@apache.org on 2026/05/28 06:25:31 UTC

(maven) branch maven-4.0.x-test-fixes updated (daaf8f933c -> f5b8a88693)

This is an automated email from the ASF dual-hosted git repository.

gnodet pushed a change to branch maven-4.0.x-test-fixes
in repository https://gitbox.apache.org/repos/asf/maven.git


    from daaf8f933c Fix spotless formatting in PluginUpgradeStrategyTest
     new f27689a892 Fix mvnup PLUGIN_UPGRADES inconsistencies for compiler and exec plugins
     new f5b8a88693 Bump scala-maven-plugin upgrade target from 4.9.2 to 4.9.5

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../cling/invoker/mvnup/goals/PluginUpgradeStrategy.java     | 11 +++++------
 .../cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java | 12 ++++++------
 2 files changed, 11 insertions(+), 12 deletions(-)


(maven) 02/02: Bump scala-maven-plugin upgrade target from 4.9.2 to 4.9.5

Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

gnodet pushed a commit to branch maven-4.0.x-test-fixes
in repository https://gitbox.apache.org/repos/asf/maven.git

commit f5b8a886936cdb52b8d0a0fe8d21327aab9990a1
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Thu May 28 08:23:27 2026 +0200

    Bump scala-maven-plugin upgrade target from 4.9.2 to 4.9.5
    
    Version 4.9.2 still calls add() on immutable lists returned by
    Maven 4 API. The fix (commit e6d922eb) landed in 4.9.5, the first
    version published to Maven Central after the fix.
    
    Co-Authored-By: Claude Opus 4.6 <no...@anthropic.com>
---
 .../maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java      | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java b/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
index 47ffb6eddb..9732390d33 100644
--- a/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
+++ b/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
@@ -91,8 +91,8 @@ public class PluginUpgradeStrategy extends AbstractUpgradeStrategy {
             new PluginUpgrade(
                     "net.alchim31.maven",
                     "scala-maven-plugin",
-                    "4.9.2",
-                    "Versions before 4.9.2 call add() on immutable lists returned by Maven 4 API"),
+                    "4.9.5",
+                    "Versions before 4.9.5 call add() on immutable lists returned by Maven 4 API"),
             new PluginUpgrade(
                     DEFAULT_MAVEN_PLUGIN_GROUP_ID,
                     "maven-resources-plugin",
@@ -266,7 +266,7 @@ private Map<String, PluginUpgradeInfo> getPluginUpgradesMap() {
                 new PluginUpgradeInfo(DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-surefire-report-plugin", "3.5.2"));
         upgrades.put(
                 "net.alchim31.maven:scala-maven-plugin",
-                new PluginUpgradeInfo("net.alchim31.maven", "scala-maven-plugin", "4.9.2"));
+                new PluginUpgradeInfo("net.alchim31.maven", "scala-maven-plugin", "4.9.5"));
         upgrades.put(
                 DEFAULT_MAVEN_PLUGIN_GROUP_ID + ":maven-resources-plugin",
                 new PluginUpgradeInfo(DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-resources-plugin", "3.3.1"));


(maven) 01/02: Fix mvnup PLUGIN_UPGRADES inconsistencies for compiler and exec plugins

Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

gnodet pushed a commit to branch maven-4.0.x-test-fixes
in repository https://gitbox.apache.org/repos/asf/maven.git

commit f27689a892b22cebc8a197610761b74885f1d784
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Thu May 28 08:21:10 2026 +0200

    Fix mvnup PLUGIN_UPGRADES inconsistencies for compiler and exec plugins
    
    maven-compiler-plugin was listed as 3.2.0 but Maven Central only has 3.2,
    causing resolution failures. exec-maven-plugin had wrong groupId
    (org.apache.maven.plugins) and artifactId (maven-exec-plugin), inconsistent
    with getPluginUpgradesMap() which correctly uses org.codehaus.mojo:exec-maven-plugin.
    
    Co-Authored-By: Claude Opus 4.6 <no...@anthropic.com>
---
 .../cling/invoker/mvnup/goals/PluginUpgradeStrategy.java     |  5 ++---
 .../cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java | 12 ++++++------
 2 files changed, 8 insertions(+), 9 deletions(-)

diff --git a/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java b/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
index 28353a8b1e..47ffb6eddb 100644
--- a/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
+++ b/impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategy.java
@@ -67,9 +67,8 @@ public class PluginUpgradeStrategy extends AbstractUpgradeStrategy {
 
     private static final List<PluginUpgrade> PLUGIN_UPGRADES = List.of(
             new PluginUpgrade(
-                    DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-compiler-plugin", "3.2.0", MAVEN_4_COMPATIBILITY_REASON),
-            new PluginUpgrade(
-                    DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-exec-plugin", "3.2.0", MAVEN_4_COMPATIBILITY_REASON),
+                    DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-compiler-plugin", "3.2", MAVEN_4_COMPATIBILITY_REASON),
+            new PluginUpgrade("org.codehaus.mojo", "exec-maven-plugin", "3.2.0", MAVEN_4_COMPATIBILITY_REASON),
             new PluginUpgrade(
                     DEFAULT_MAVEN_PLUGIN_GROUP_ID, "maven-enforcer-plugin", "3.5.0", MAVEN_4_COMPATIBILITY_REASON),
             new PluginUpgrade("org.codehaus.mojo", "flatten-maven-plugin", "1.2.7", MAVEN_4_COMPATIBILITY_REASON),
diff --git a/impl/maven-cli/src/test/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java b/impl/maven-cli/src/test/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java
index 17dc1859db..149b341956 100644
--- a/impl/maven-cli/src/test/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java
+++ b/impl/maven-cli/src/test/java/org/apache/maven/cling/invoker/mvnup/goals/PluginUpgradeStrategyTest.java
@@ -521,8 +521,8 @@ void shouldNotUpgradePluginWithoutVersion() throws Exception {
                     <build>
                         <plugins>
                             <plugin>
-                                <groupId>org.apache.maven.plugins</groupId>
-                                <artifactId>maven-exec-plugin</artifactId>
+                                <groupId>org.codehaus.mojo</groupId>
+                                <artifactId>exec-maven-plugin</artifactId>
                                 <!-- No version - inherited from parent or pluginManagement -->
                             </plugin>
                         </plugins>
@@ -553,8 +553,8 @@ void shouldNotUpgradeWhenPropertyNotFound() throws Exception {
                     <build>
                         <plugins>
                             <plugin>
-                                <groupId>org.apache.maven.plugins</groupId>
-                                <artifactId>maven-exec-plugin</artifactId>
+                                <groupId>org.codehaus.mojo</groupId>
+                                <artifactId>exec-maven-plugin</artifactId>
                                 <version>${exec.plugin.version}</version>
                             </plugin>
                         </plugins>
@@ -737,7 +737,7 @@ void shouldHavePredefinedPluginUpgrades() throws Exception {
             boolean hasCompilerPlugin =
                     upgrades.stream().anyMatch(upgrade -> "maven-compiler-plugin".equals(upgrade.artifactId()));
             boolean hasExecPlugin =
-                    upgrades.stream().anyMatch(upgrade -> "maven-exec-plugin".equals(upgrade.artifactId()));
+                    upgrades.stream().anyMatch(upgrade -> "exec-maven-plugin".equals(upgrade.artifactId()));
             boolean hasSurefirePlugin =
                     upgrades.stream().anyMatch(upgrade -> "maven-surefire-plugin".equals(upgrade.artifactId()));
             boolean hasFailsafePlugin =
@@ -746,7 +746,7 @@ void shouldHavePredefinedPluginUpgrades() throws Exception {
                     upgrades.stream().anyMatch(upgrade -> "maven-surefire-report-plugin".equals(upgrade.artifactId()));
 
             assertTrue(hasCompilerPlugin, "Should include maven-compiler-plugin upgrade");
-            assertTrue(hasExecPlugin, "Should include maven-exec-plugin upgrade");
+            assertTrue(hasExecPlugin, "Should include exec-maven-plugin upgrade");
             assertTrue(hasSurefirePlugin, "Should include maven-surefire-plugin upgrade");
             assertTrue(hasFailsafePlugin, "Should include maven-failsafe-plugin upgrade");
             assertTrue(hasSurefireReportPlugin, "Should include maven-surefire-report-plugin upgrade");