[
https://jira.codehaus.org/browse/MPIR-313?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=358874#comment-358874
]
Constantino Cronemberger edited comment on MPIR-313 at 12/10/14 7:22 AM:
-------------------------------------------------------------------------
At that point in the code we don't have access to the logger because the inner
class (LicenseRenderer) is static, so we would need to pass the Log instance to
it.
I have searched for other exceptions already in use by the plugin and
AssertionError was one of them. I also thought about IllegalArgumentException,
but did not like it because the license is not really an argument of the method.
was (Author: ccronemberger):
At that point in the code we don't have access to the logger because the inner
class (LicenseRenderer) is static, so we would need to pass the Log instance to
it.
I have searched for other exceptions already in use by the plugin and
AssertionError was one of them. I also though about IllegalArgumentException,
but did not like it because the license is not really an argument of the method.
> url and name are mandatory for a license but this is not validated
> ------------------------------------------------------------------
>
> Key: MPIR-313
> URL: https://jira.codehaus.org/browse/MPIR-313
> Project: Maven Project Info Reports Plugin
> Issue Type: Bug
> Affects Versions: 2.7
> Reporter: Constantino Cronemberger
> Assignee: Michael Osipov
> Priority: Minor
> Labels: exception
> Attachments: exception.txt,
> fix_MPIR-313_-_license_name_is_mandatory_because_it_is_used_to_create_an_HTML_anchor.patch,
> pom.xml
>
>
> In an internal project we had a license defined in the pom.xml but without
> url and name.
> This causes an exception which does not say anything about the fact that
> these required elements are missing. See attached file with the complete
> exception.
> {code}
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-site-plugin:3.3:site (default-site) on project
> jee-util: Execution default-site of goal
> org.apache.maven.plugins:maven-site-plugin:3.3:site failed: Anchor name
> cannot be null! -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
> goal org.apache.maven.plugins:maven-site-plugin:3.3:site (default-site) on
> project jee-util: Execution default-site of goal
> org.apache.maven.plugins:maven-site-plugin:3.3:site failed: Anchor name
> cannot be null!
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
> {code}
--
This message was sent by Atlassian JIRA
(v6.1.6#6162)