-
Notifications
You must be signed in to change notification settings - Fork 68
Closed
Labels
bugSomething isn't workingSomething isn't workingpriority:majorMajor loss of functionMajor loss of function
Milestone
Description
Maciej Gorywoda opened MPLUGIN-373 and commented
Even though compilation works, mvn install fails with:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-plugin-plugin:3.6.1:descriptor (default-descriptor) on project maven-plugin-minimal: Execution default-descriptor of goal org.apache.maven.plugins:maven-plugin-plugin:3.6.1:descriptor failed: syntax error @[27,1] in [file:/home/makingthematrix/workspace/maven-plugin-minimal/src/main/java/io/makingthematrix/MinimalMojo.java|file:///home/makingthematrix/workspace/maven-plugin-minimal/src/main/java/io/makingthematrix/MinimalMojo.java] -> [Help 1]
That syntax error @[27,1] is
record KaBoom(String foo) {}
Tested on openjdk-16 and graalvm-21.1.0 for Java 16.
maven-compiler-plugin version: 3.8.1
maven-plugin-plugin version: 3.6.1
I made a minimal example and put it on GitHub: https://github.com/makingthematrix/maven-plugin-minimal
And here are the logs:
—
makingthematrix@makingthematrix:~/workspace/maven-plugin-minimal$ java -version
openjdk version "16.0.1" 2021-04-20
OpenJDK Runtime Environment (build 16.0.1+9-24)
OpenJDK 64-Bit Server VM (build 16.0.1+9-24, mixed mode, sharing)
makingthematrix@makingthematrix:~/workspace/maven-plugin-minimal$ mvn --version
Apache Maven 3.8.1 (05c21c65bdfed0f71a2f2ada8b84da59348c4c5d)
Maven home: /opt/mvn
Java version: 16.0.1, vendor: Oracle Corporation, runtime: /opt/jdk-16.0.1
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.4.0-71-generic", arch: "amd64", family: "unix"
makingthematrix@makingthematrix:~/workspace/maven-plugin-minimal$ mvn clean
[INFO] Scanning for projects...
[INFO]
[INFO] --------------< io.makingthematrix:maven-plugin-minimal >---------------
[INFO] Building Maven Plugin Minimal 0.0.1
[INFO] ----------------------------[ maven-plugin ]----------------------------
[INFO]
[INFO] — maven-clean-plugin:2.5:clean (default-clean) @ maven-plugin-minimal —
[INFO] Deleting /home/makingthematrix/workspace/maven-plugin-minimal/target
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.184 s
[INFO] Finished at: 2021-04-30T19:07:36+02:00
[INFO] ------------------------------------------------------------------------
makingthematrix@makingthematrix:~/workspace/maven-plugin-minimal$ mvn compile
[INFO] Scanning for projects...
[INFO]
[INFO] --------------< io.makingthematrix:maven-plugin-minimal >---------------
[INFO] Building Maven Plugin Minimal 0.0.1
[INFO] ----------------------------[ maven-plugin ]----------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ maven-plugin-minimal —
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /home/makingthematrix/workspace/maven-plugin-minimal/src/main/resources
[INFO]
[INFO] — maven-compiler-plugin:3.8.1:compile (default-compile) @ maven-plugin-minimal —
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 1 source file to /home/makingthematrix/workspace/maven-plugin-minimal/target/classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.262 s
[INFO] Finished at: 2021-04-30T19:08:15+02:00
[INFO] ------------------------------------------------------------------------
makingthematrix@makingthematrix:~/workspace/maven-plugin-minimal$ mvn install
[INFO] Scanning for projects...
[INFO]
[INFO] --------------< io.makingthematrix:maven-plugin-minimal >---------------
[INFO] Building Maven Plugin Minimal 0.0.1
[INFO] ----------------------------[ maven-plugin ]----------------------------
[INFO]
[INFO] — maven-resources-plugin:2.6:resources (default-resources) @ maven-plugin-minimal —
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /home/makingthematrix/workspace/maven-plugin-minimal/src/main/resources
[INFO]
[INFO] — maven-compiler-plugin:3.8.1:compile (default-compile) @ maven-plugin-minimal —
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] — maven-plugin-plugin:3.6.1:descriptor (default-descriptor) @ maven-plugin-minimal —
[WARNING] Using platform encoding (UTF-8 actually) to read mojo source files, i.e. build is platform dependent!
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.044 s
[INFO] Finished at: 2021-04-30T19:08:44+02:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-plugin-plugin:3.6.1:descriptor (default-descriptor) on project maven-plugin-minimal: Execution default-descriptor of goal org.apache.maven.plugins:maven-plugin-plugin:3.6.1:descriptor failed: syntax error @[27,1] in [file:/home/makingthematrix/workspace/maven-plugin-minimal/src/main/java/io/makingthematrix/MinimalMojo.java|file:///home/makingthematrix/workspace/maven-plugin-minimal/src/main/java/io/makingthematrix/MinimalMojo.java] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] [http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException]
Affects: 3.6.1
Issue Links:
- MPLUGIN-381 Upgrade QDox to 2.0.1
("depends upon")
Remote Links:
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingpriority:majorMajor loss of functionMajor loss of function