← All tasks
javagoogle/error-prone #1986Not a task: not reproduced

java.lang.ExceptionInInitializerError in AutoValueSubclassLeaked caused by NullPointerException in Caffeine

envgap__google__error-prone-1986

01 / FAILURE SIGNATURE

As reported upstream

I'm getting the following crash inside error-prone on Java 8. Works fine on Java 11. It's not urgent for me, I'm happy to not support building on Java 8 at this point.
Not a benchmark task.
  • In a clean container the reported failure did not reproduce, or the known fix did not make the project run.

02 / ENVIRONMENT RECIPE

Base commit
156c7a545f7fcc751562c352ef3373d430e0c3e1
Manifest
pom.xml
Reproduce
Awaiting issue-specific recipe
Run under trace
Awaiting a meaningful runtime command

03 / ORIGINAL ISSUE TEXT

google/error-prone #1986 · read the original issue
I'm getting the following crash inside error-prone on Java 8. Works fine on Java 11. It's not urgent for me, I'm happy to not support building on Java 8 at this point.



```

     error-prone version: 2.4.0

     BugPattern: AutoValueSubclassLeaked

     Stack Trace:

     java.lang.ExceptionInInitializerError

        at com.google.errorprone.bugpatterns.AutoValueSubclassLeaked$1.handle(AutoValueSubclassLeaked.java:83)

        at com.google.errorprone.bugpatterns.AutoValueSubclassLeaked$1.visitMemberSelect(AutoValueSubclassLeaked.java:72)

        at com.google.errorprone.bugpatterns.AutoValueSubclassLeaked$1.visitMemberSelect(AutoValueSubclassLeaked.java:69)

        at com.sun.tools.javac.tree.JCTree$JCFieldAccess.accept(JCTree.java:2112)

    <snip>

      Caused by: java.lang.NullPointerException

        at com.github.benmanes.caffeine.cache.LocalCacheFactory.newBoundedLocalCache(LocalCacheFactory.java:95)

        at com.github.benmanes.caffeine.cache.BoundedLocalCache$BoundedLocalManualCache.<init>(BoundedLocalCache.java:3392)

        at com.github.benmanes.caffeine.cache.BoundedLocalCache$BoundedLocalManualCache.<init>(BoundedLocalCache.java:3388)

        at com.github.benmanes.caffeine.cache.Caffeine.build(Caffeine.java:988)

        at com.google.errorprone.util.ASTHelpers.<clinit>(ASTHelpers.java:722)

        ... 66 more

```



### To reproduce



Make sure OpenJDK 8 is available in JAVA_HOME, this example assumes it's in `/usr/lib/java-8-openjdk-amd64/`.



```

$ git clone git@github.com:sjamesr/jfreesane.git

$ cd jfreesane

$ git fetch origin pull/102/head

$ git checkout FETCH_HEAD

$ JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/ ./gradlew check

```



### What version of Error Prone are you using?



2.4.0, invoked by net.ltgt.errorprone plugin version 1.3.0.



###  Have you found anything relevant by searching the web?



No luck.
Continue on GitHub ↗

04 / LABELS

Labels from the report text only; not yet run

No supported category has been assigned.

Label rules and the text that matched
[]