google/auto

ServiceLoader$LazyIterator.nextService NullPointerException

SJLBenjamin opened this issue · 2 comments

java.lang.NullPointerException
at java.lang.Class.classForName(Native Method)
at java.lang.Class.forName(Class.java:454)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:371)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:416)
at java.util.ServiceLoader$1.next(ServiceLoader.java:494)
at c80.e1(SourceFile:5)
at c80.u(SourceFile:1)
at c80$s0.invokeSuspend(SourceFile:16)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(SourceFile:4)
at zf.run(SourceFile:22)
at by.run(SourceFile:2)
at kn0.run(SourceFile:1)
at ic.k(SourceFile:1)
at ic$c.d(SourceFile:4)
at ic$c.n(SourceFile:4)
at ic$c.run(SourceFile:1)
Suppressed: lf: [il0{Cancelling}@c9238bc, Dispatchers.IO]

I'm not entirely sure what the problem is, but I suspect it's not specific to AutoService. My best guess would be that two threads are trying to iterate over the same ServiceLoader Iterator at the same time. If you need more help, I suggest trying Stack Overflow, ideally with a stack trace from an app that hasn't been minified and with some of the source code.

This is presumably about AutoService rather than AutoValue, but I agree with @cpovirk that the problem is very likely to be elsewhere.