[ 
https://issues.apache.org/jira/browse/MPIR-400?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17258160#comment-17258160
 ] 

Marwa Khabbaz commented on MPIR-400:
------------------------------------

I changed my example a bit because it lead to confusion. Yes, I meant 
inheritance.
I have the following structure for my project:
* The child module is on the same level in the directory.
* The child modules directly inherit from the parent module.
* In the {{pom.xml}} of the parent module, extensions are used.

I uploaded the file [^example.zip] where you can check the structure.

Now the problem is: When the parent has extensions and the child module 
directly inherits from the parent module, the build {{mvn -pl . clean site 
site:stage}} fails with a {{NullPointerException}} for the parent module. When 
I leave out the {{</parent>}}-section in the child module, the build works 
perfectly.

> mvn -pl . clean site site:stage fails when extensions are part of pom.xml
> -------------------------------------------------------------------------
>
>                 Key: MPIR-400
>                 URL: https://issues.apache.org/jira/browse/MPIR-400
>             Project: Maven Project Info Reports Plugin
>          Issue Type: Bug
>          Components: index, modules
>    Affects Versions: 3.0.0, 3.1.0, 3.1.1
>         Environment: Apache Maven Version: 3.6.3
> Java version: 1.8.0_251, vendor: Oracle Corporation, runtime: C:\Program 
> Files\Java\jdk1.8.0_251\jre
> OS name: "windows 7", version: "6.1", arch: "amd64", family: "windows"
>            Reporter: Marwa Khabbaz
>            Priority: Major
>             Fix For: waiting-for-feedback
>
>         Attachments: error_log.txt, example.zip, pom_aggregator.xml, 
> pom_sub-module.xml
>
>
> I have a project consisting of an aggregator and a submodule, which inherits 
> directly from the aggregator. I have the following scenarios:
>  * When I execute {{mvn clean site site:stage}} (without {{-pl .}}), the 
> build is successful.
>  * When I leave out the extensions out of the {{pom.xml}}-file of my 
> aggregator and execute the {{mvn -pl . clean site site:stage}}, the build is 
> successful.
>  * When I put in extensions to the {{pom.xml}}-file of my aggregator but 
> leave out the reports for {{index}} and {{modules}} (the only sites that 
> refer to my submodule) by explicitly defining the report set in the 
> {{pom.xml}}-file of the aggregator, the build is successful.
>  * As soon as I put extensions into the {{pom.xml}}-file of my aggregator and 
> leave in the reports for {{index}} and {{modules}}, then execute the build 
> {{mvn -pl . clean site site:stage}} for the aggregator, the build fails with 
> a {{NullPointerException}}.
> I attached the error log of the last scenario and the {{pom.xml}} of the 
> aggregator and its submodule to this ticket. This has never been a problem 
> until the release of {{maven-project-info-reports-plugin 3.0.0}}.
> Hopefully I managed to understandably describe my issue.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to