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

[BUG] NullpointerException when running ossIndexAudit #79

Closed
rprinsen opened this issue May 4, 2021 · 1 comment · Fixed by #96
Closed

[BUG] NullpointerException when running ossIndexAudit #79

rprinsen opened this issue May 4, 2021 · 1 comment · Fixed by #96
Assignees
Labels
bug Something isn't working

Comments

@rprinsen
Copy link

rprinsen commented May 4, 2021

When running the ossIndexAudit task I get the following NullpointerException:


Caused by: java.lang.NullPointerException
        at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.getDependenciesMapWithVulnerabilities(DependencyGraphResponseHandler.java:174)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.handleOssIndexResponse(DependencyGraphResponseHandler.java:57)
        at org.sonatype.gradle.plugins.scan.ossindex.OssIndexAuditTask.audit(OssIndexAuditTask.java:105)
        ... 123 more
Caused by: java.lang.NullPointerException
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.hasVulnerabilities(DependencyGraphResponseHandler.java:183)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.lambda$hasVulnerabilities$3(DependencyGraphResponseHandler.java:184)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.hasVulnerabilities(DependencyGraphResponseHandler.java:185)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.lambda$hasVulnerabilities$3(DependencyGraphResponseHandler.java:184)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.hasVulnerabilities(DependencyGraphResponseHandler.java:185)
        at org.sonatype.gradle.plugins.scan.ossindex.DependencyGraphResponseHandler.lambda$getDependenciesMapWithVulnerabilities$2(DependencyGraphResponseHandler.java:173)

Am using version 2.0.9. Here's my gradle config:

ossIndexAudit {
    isDependencyGraph = true
    isPrintBanner = false
}
@rprinsen rprinsen added the bug Something isn't working label May 4, 2021
@guillermo-varela
Copy link
Contributor

guillermo-varela commented May 4, 2021

Hi @rprinsen,

Would it be possible for you to please share here a sample project where you are getting that error?
It would be very helpful for us to reproduce the error and finding a fix.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants