[ http://jira.codehaus.org/browse/MPIR-131?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=163056#action_163056 ]
Thiago Leão Moreira commented on MPIR-131: ------------------------------------------ This issue is easy reproduced with a project where all the dependencies has the "system" scope. > NPE in printArtifactsLocations() for blacklisted repo > ----------------------------------------------------- > > Key: MPIR-131 > URL: http://jira.codehaus.org/browse/MPIR-131 > Project: Maven 2.x Project Info Reports Plugin > Issue Type: Bug > Components: dependencies > Affects Versions: 2.1 > Environment: Linux (Sun JDK 1.6), Windows (IBM VM 1.4). No direct > Internet access; going through local Artifactory repository. > Reporter: Klaus Brunner > Priority: Critical > Attachments: screenshot-1.jpg > > > I'm getting NPEs when running the reports plugin at this location: > [INFO] Generating "Dependencies" report. > [WARNING] The repository url 'http://repo1.maven.org/maven2' is invalid - > Repository 'central' will be blacklisted. > [INFO] > ------------------------------------------------------------------------ > [ERROR] FATAL ERROR > [INFO] > ------------------------------------------------------------------------ > [INFO] null > [INFO] > ------------------------------------------------------------------------ > [INFO] Trace > java.lang.NullPointerException > at > org.apache.maven.report.projectinfo.dependencies.renderer.DependenciesRenderer.printArtifactsLocations(DependenciesRenderer.java:1182) > at > org.apache.maven.report.projectinfo.dependencies.renderer.DependenciesRenderer.renderSectionDependencyRepositoryLocations(DependenciesRenderer.java:641) > at > org.apache.maven.report.projectinfo.dependencies.renderer.DependenciesRenderer.renderBody(DependenciesRenderer.java:274) > at > org.apache.maven.reporting.AbstractMavenReportRenderer.render(AbstractMavenReportRenderer.java:65) > at > org.apache.maven.report.projectinfo.DependenciesReport.executeReport(DependenciesReport.java:239) > Taking a brief look with the debugger, it appears that the totalByRepo map in > DependenciesRenderer.printArtifactsLocations() is empty - so looking up any > entry will of course return null and result in an NPE here: > totalRow[idnum++] = totalByRepo.get( repokey ).toString(); > Note that this used to work fine before the 2.1 release. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira