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

Document required min Maven version #513

Open
eva-mueller-coremedia opened this issue Jan 22, 2025 · 1 comment
Open

Document required min Maven version #513

eva-mueller-coremedia opened this issue Jan 22, 2025 · 1 comment

Comments

@eva-mueller-coremedia
Copy link
Contributor

Describe your use-case which is not covered by existing documentation.

Documentation

Highlight to use at least Maven 3.9.6 when developing this plugin.

Background

With the new parent

<parent>
  <groupId>org.jenkins-ci.plugins</groupId>
  <artifactId>plugin</artifactId>
  <version>5.3</version>
  <relativePath />
</parent>

Maven 3.9.6 is required

If you build with Maven < 3.9.6, you will get the following cryptic error:

Unknown packaging: hpi @ org.jenkins-ci.plugins:PLUGIN:${revision}.${changelist}, /pom.xml, line 13, column 14

[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[ERROR] Unknown packaging: hpi @ org.jenkins-ci.plugins:PLUGIN:${revision}.${changelist}, <PATH_TO_POM>/pom.xml, line 13, column 14
 @ 
[ERROR] The build could not read 1 project -> [Help 1]
org.apache.maven.project.ProjectBuildingException: Some problems were encountered while processing the POMs:
[ERROR] Unknown packaging: hpi @ org.jenkins-ci.plugins:PLUGIN:${revision}.${changelist}, <PATH_TO_POM>/pom.xml, line 13, column 14

    at org.apache.maven.project.DefaultProjectBuilder.build (DefaultProjectBuilder.java:389)
    at org.apache.maven.graph.DefaultGraphBuilder.collectProjects (DefaultGraphBuilder.java:349)
    at org.apache.maven.graph.DefaultGraphBuilder.getProjectsForMavenReactor (DefaultGraphBuilder.java:340)
    at org.apache.maven.graph.DefaultGraphBuilder.build (DefaultGraphBuilder.java:76)
    at org.apache.maven.DefaultMaven.buildGraph (DefaultMaven.java:448)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:197)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:827)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:272)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:195)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:77)
    at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke (Method.java:568)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
[ERROR]   
[ERROR]   The project org.jenkins-ci.plugins:PLUGIN:4.999999-SNAPSHOT (<PATH_TO_POM>/pom.xml) has 1 error
[ERROR]     Unknown packaging: hpi @ org.jenkins-ci.plugins:PLUGIN:${revision}.${changelist}, <PATH_TO_POM>/pom.xml, line 13, column 14
[ERROR] 
[ERROR] 

<PATH_TO_POM>/pom.xml, line 13, column 14 is <packaging>hpi</packaging>.

Source Code

I then had a look at the source code and saw

Reference any relevant documentation, other materials or issues/pull requests that can be used for inspiration.

No response

Are you interested in contributing to the documentation?

No response

@programbeginnerTW
Copy link

@eva-mueller-coremedia, I've added the Maven version notice inside /docs/CONTRIBUTING.md.
Here's the PR link: PR#514

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants