You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Seen in a variety of Guava classes, such as FluentFuture.
This might be the only crash that I've seen so far in my internal testing. But as noted in #159, one crash could be hiding others :)
For the moment, I'm going to dump the stack trace below. Then I'm going to see if it still reproduces with my fix for #159 in place, as I see inheritOverriddenDeclAnnos in the stack in both.
Last visited tree at line 81 column 1:
@DoNotMock("Use FluentFuture.from(Futures.immediate*Future) or SettableFuture")
Exception: java.lang.NullPointerException: Cannot invoke "com.sun.source.tree.Tree.getKind()" because "tree" is null; java.lang.NullPointerException: Cannot invoke "com.sun.source.tree.Tree.getKind()" because "tree" is null
at jdk.compiler/com.sun.source.util.TreePath.<init>(TreePath.java:118)
at jdk.compiler/com.sun.source.util.TreePath.<init>(TreePath.java:109)
at jdk.compiler/com.sun.source.util.TreePath.getPath(TreePath.java:50)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getPath(AnnotatedTypeFactory.java:3982)
at org.checkerframework.framework.util.defaults.QualifierDefaults.nearestEnclosingExceptLocal(QualifierDefaults.java:503)
at org.checkerframework.framework.util.defaults.QualifierDefaults.applyDefaults(QualifierDefaults.java:581)
at org.checkerframework.framework.util.defaults.QualifierDefaults.annotate(QualifierDefaults.java:489)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.addComputedTypeAnnotations(GenericAnnotatedTypeFactory.java:2062)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.addComputedTypeAnnotations(GenericAnnotatedTypeFactory.java:1991)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getAnnotatedTypeFromTypeTree(AnnotatedTypeFactory.java:1556)
at org.checkerframework.framework.type.SupertypeFinder$SupertypeFindingVisitor.supertypesFromTree(SupertypeFinder.java:338)
at org.checkerframework.framework.type.SupertypeFinder$SupertypeFindingVisitor.visitDeclared(SupertypeFinder.java:191)
at org.checkerframework.framework.type.SupertypeFinder.directSupertypes(SupertypeFinder.java:63)
at org.checkerframework.framework.type.AnnotatedTypeMirror$AnnotatedDeclaredType.directSupertypes(AnnotatedTypeMirror.java:1137)
at org.checkerframework.framework.util.AnnotatedTypes.getSuperTypes(AnnotatedTypes.java:646)
at org.checkerframework.framework.util.AnnotatedTypes.overriddenMethods(AnnotatedTypes.java:667)
at org.checkerframework.framework.type.AnnotatedTypeFactory.inheritOverriddenDeclAnnos(AnnotatedTypeFactory.java:4358)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getDeclAnnotations(AnnotatedTypeFactory.java:4296)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getDeclAnnotation(AnnotatedTypeFactory.java:4219)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getDeclAnnotation(AnnotatedTypeFactory.java:4197)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getDeclAnnotation(AnnotatedTypeFactory.java:4117)
at org.checkerframework.framework.util.defaults.QualifierDefaults.defaultsAtDirect(QualifierDefaults.java:765)
at org.checkerframework.framework.util.defaults.QualifierDefaults.defaultsAt(QualifierDefaults.java:713)
at org.checkerframework.framework.util.defaults.QualifierDefaults.defaultsAt(QualifierDefaults.java:727)
at org.checkerframework.framework.util.defaults.QualifierDefaults.applyDefaultsElement(QualifierDefaults.java:855)
at org.checkerframework.framework.util.defaults.QualifierDefaults.annotate(QualifierDefaults.java:479)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.addComputedTypeAnnotations(GenericAnnotatedTypeFactory.java:2292)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getAnnotatedType(AnnotatedTypeFactory.java:1441)
at com.google.jspecify.nullness.NullSpecAnnotatedTypeFactory.getUpperBounds(NullSpecAnnotatedTypeFactory.java:708)
at com.google.jspecify.nullness.NullSpecAnnotatedTypeFactory.nullnessEstablishingPathExists(NullSpecAnnotatedTypeFactory.java:681)
at com.google.jspecify.nullness.NullSpecAnnotatedTypeFactory.isNullExclusiveUnderEveryParameterization(NullSpecAnnotatedTypeFactory.java:621)
at com.google.jspecify.nullness.NullSpecAnnotatedTypeFactory$NullSpecTypeVariableSubstitutor.substituteTypeVariable(NullSpecAnnotatedTypeFactory.java:855)
at org.checkerframework.framework.type.TypeVariableSubstitutor$Visitor.visitTypeVariable(TypeVariableSubstitutor.java:173)
at org.checkerframework.framework.type.TypeVariableSubstitutor$Visitor.visitTypeVariable(TypeVariableSubstitutor.java:82)
at org.checkerframework.framework.type.AnnotatedTypeMirror$AnnotatedTypeVariable.accept(AnnotatedTypeMirror.java:1861)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visit(AnnotatedTypeCopier.java:102)
at org.checkerframework.framework.type.AnnotatedTypeCopier.lambda$visitDeclared$0(AnnotatedTypeCopier.java:127)
at org.checkerframework.org.plumelib.util.CollectionsPlume.mapList(CollectionsPlume.java:444)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visitDeclared(AnnotatedTypeCopier.java:126)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visitDeclared(AnnotatedTypeCopier.java:44)
at org.checkerframework.framework.type.AnnotatedTypeMirror$AnnotatedDeclaredType.accept(AnnotatedTypeMirror.java:1058)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visit(AnnotatedTypeCopier.java:102)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visitExecutable(AnnotatedTypeCopier.java:202)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visitExecutable(AnnotatedTypeCopier.java:44)
at org.checkerframework.framework.type.AnnotatedTypeMirror$AnnotatedExecutableType.accept(AnnotatedTypeMirror.java:1265)
at org.checkerframework.framework.type.AnnotatedTypeCopier.visit(AnnotatedTypeCopier.java:95)
at org.checkerframework.framework.type.TypeVariableSubstitutor.substitute(TypeVariableSubstitutor.java:34)
at org.checkerframework.framework.type.AnnotatedTypeFactory.methodFromUse(AnnotatedTypeFactory.java:2591)
at org.checkerframework.framework.type.AnnotatedTypeFactory.methodFromUse(AnnotatedTypeFactory.java:2503)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.methodFromUse(GenericAnnotatedTypeFactory.java:2298)
at org.checkerframework.framework.type.TypeFromExpressionVisitor.visitMethodInvocation(TypeFromExpressionVisitor.java:413)
at org.checkerframework.framework.type.TypeFromExpressionVisitor.visitMethodInvocation(TypeFromExpressionVisitor.java:81)
at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCMethodInvocation.accept(JCTree.java:1832)
at jdk.compiler/com.sun.source.util.SimpleTreeVisitor.visit(SimpleTreeVisitor.java:81)
at org.checkerframework.framework.type.TypeFromTree.fromExpression(TypeFromTree.java:42)
at org.checkerframework.framework.type.AnnotatedTypeFactory.fromExpression(AnnotatedTypeFactory.java:1843)
at org.checkerframework.framework.type.AnnotatedTypeFactory.getAnnotatedType(AnnotatedTypeFactory.java:1486)
at org.checkerframework.framework.flow.CFAbstractTransfer.getValueFromFactory(CFAbstractTransfer.java:215)
at org.checkerframework.framework.flow.CFAbstractTransfer.visitMethodInvocation(CFAbstractTransfer.java:999)
at com.google.jspecify.nullness.NullSpecTransfer.visitMethodInvocation(NullSpecTransfer.java:152)
at com.google.jspecify.nullness.NullSpecTransfer.visitMethodInvocation(NullSpecTransfer.java:75)
at org.checkerframework.dataflow.cfg.node.MethodInvocationNode.accept(MethodInvocationNode.java:124)
at org.checkerframework.dataflow.analysis.AbstractAnalysis.callTransferFunction(AbstractAnalysis.java:356)
at org.checkerframework.dataflow.analysis.ForwardAnalysisImpl.callTransferFunction(ForwardAnalysisImpl.java:393)
at org.checkerframework.dataflow.analysis.ForwardAnalysisImpl.performAnalysisBlock(ForwardAnalysisImpl.java:157)
at org.checkerframework.dataflow.analysis.ForwardAnalysisImpl.performAnalysis(ForwardAnalysisImpl.java:110)
at org.checkerframework.framework.flow.CFAbstractAnalysis.performAnalysis(CFAbstractAnalysis.java:150)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.analyze(GenericAnnotatedTypeFactory.java:1623)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.performFlowAnalysis(GenericAnnotatedTypeFactory.java:1513)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.checkAndPerformFlowAnalysis(GenericAnnotatedTypeFactory.java:2100)
at org.checkerframework.framework.type.GenericAnnotatedTypeFactory.preProcessClassTree(GenericAnnotatedTypeFactory.java:435)
at com.google.jspecify.nullness.NullSpecAnnotatedTypeFactory.preProcessClassTree(NullSpecAnnotatedTypeFactory.java:1684)
at org.checkerframework.common.basetype.BaseTypeVisitor.visitClass(BaseTypeVisitor.java:591)
at org.checkerframework.common.basetype.BaseTypeVisitor.visitClass(BaseTypeVisitor.java:195)
at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:855)
at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:66)
at org.checkerframework.framework.source.SourceVisitor.visit(SourceVisitor.java:89)
at org.checkerframework.framework.source.SourceChecker.typeProcess(SourceChecker.java:1136)
at org.checkerframework.common.basetype.BaseTypeChecker.typeProcess(BaseTypeChecker.java:556)
at com.google.jspecify.nullness.NullSpecChecker.typeProcess(NullSpecChecker.java:106)
at org.checkerframework.javacutil.AbstractTypeProcessor$AttributionTaskListener.finished(AbstractTypeProcessor.java:193)
at jdk.compiler/com.sun.tools.javac.api.ClientCodeWrapper$WrappedTaskListener.finished(ClientCodeWrapper.java:876)
at jdk.compiler/com.sun.tools.javac.api.MultiTaskListener.finished(MultiTaskListener.java:133)
at jdk.compiler/com.sun.tools.javac.main.JavaCompiler.flow(JavaCompiler.java:1443)
The text was updated successfully, but these errors were encountered:
Yes, this goes away with the fix for #159. (And I don't see any other crashes, though again, I don't think the checker was even able to attempt to build all the targets we use it on yet.) I'll close this bug in favor of that one.
(I have now gotten myself confused about exactly which configurations I've tested. Notably, I may have used the old jspecify/checker-framework fork in one or both rounds of internal testing instead of using eisop/checker-framework? I could retrace my steps further here, but for now, I'm just going to make sure that I have (a) the latest errors and (b) a proper testing setup for the future. As best I recall, I did produce standalone reproducers for the other problems I reported, so I don't think this calls any of them into question.)
(At this point, I now think that I did get both rounds of internal testing right. I just got confused today because I thought I was retesting the late-March code (PR #165) but I saw this error from the early-February code. But in fact I was accidentally retesting the early-February code, so it makes perfect sense that I would see this early-February error.)
Seen in a variety of Guava classes, such as
FluentFuture
.This might be the only crash that I've seen so far in my internal testing. But as noted in #159, one crash could be hiding others :)
For the moment, I'm going to dump the stack trace below. Then I'm going to see if it still reproduces with my fix for #159 in place, as I see
inheritOverriddenDeclAnnos
in the stack in both.The text was updated successfully, but these errors were encountered: