Skip to content

Releases: uber/NullAway

NullAway 0.12.14

04 Dec 18:08

Choose a tag to compare

This release fixes a bug where the new RequireExplicitNullMarking check was not fully disabled by default. It also includes a couple of performance optimizations to reduce NullAway overhead.

  • Various optimizations (#1358)
  • Don't report matches from RequireExplicitNullMarking when run at SUGGESTION level (#1365)
  • Optimize methods that check for annotations on a Symbol (#1362)
  • Tune warning message for RequireExplicitNullMarking (#1366)
  • Maintenance
    • Fix arg concatenation bug in JMH (#1357)
    • Move wildcard-related tests to a separate test class (#1361)

NullAway 0.12.13

01 Dec 15:30

Choose a tag to compare

NullAway now includes a new Error Prone checker, RequireExplicitNullMarking, that checks that every class is explicitly @NullMarked or @NullUnmarked (at the class or package level), so code is not left @NullUnmarked unintentionally. The check is disabled by default. See the docs for further details.

NullAway also includes support for a new @PureExceptLambda annotation, contributed by @FxMorin, to tell NullAway
to preserve nullability information from the enclosing method when analyzing the body of certain lambdas.
See the docs for details.

  • Use passed-in TreePath in one more place when available (#1329)
  • Checker to ensure explicit null marking of every class (#1323)
  • Bound size of alreadyRunAnalyses cache to be consistent (#1334)
  • Improve inference for generic methods with lambda argument containing return statements by @dhruv-agr (#1337)
  • Add PureExceptLambda annotation by @FxMorin (#1325)
  • Support marking method type variable upper bounds as @Nullable in library models (#1345)
  • Method name parsing in ExternalStubxLibraryModels class is missing a corner case by @haewiful (#1344)
  • Better fix for dataflow analysis caching (#1353)
  • Maintenance
    • Add package-info files with @NullMarked (#1331)
    • Speed up buildWithNullAway task (#1330)
    • Enable the VoidMissingNullable checker and autofix all extant warnings (#1332)
    • Bump JDK version to 25 for integration tests (#1336)
    • Switch Coderabbit to assertive mode (#1338)
    • Enable EqualsMissingNullable check and fix all extant warnings (#1339)
    • Bump to AutoValue 1.11.1 (#1340)
    • Update Caffeine benchmark (#1342)
    • Add a test for a useless @contract (#1346)
    • Test case for wildcards in Generic Method with Lambda Arguments by @dhruv-agr (#1349)
    • Add initial AGENTS.md file (#1352)

NullAway 0.12.12

04 Nov 19:27

Choose a tag to compare

This release fixes a severe performance regression introduced in NullAway 0.12.11 and we encourage all users of 0.12.11 to upgrade.

  • Address severe performance regression in dataflow analysis (#1328)
  • Maintenance
    • Fix test args for SuggestedFixesTests (#1324)
    • Stop passing -processorpath to CompilationTestHelper in NullAway tests (#1326)

NullAway 0.12.11

31 Oct 15:19

Choose a tag to compare

Version 0.12.11

In this release, NullAway checks the requirement that JSpecify mode is only run on a compatible javac version /
configuration, and fails if it detects an incompatibility.
See https://github.com/uber/NullAway/wiki/JSpecify-Support#supported-jdk-versions for details.

  • Use inference for generic call passed as receiver to instance method (#1293)
  • Accept any annotation with simple name Contract, and change reporting of invalid contract annotations (#1295)
  • Properly model AtomicReference.get() in JSpecify mode (#1298)
  • Improve handling and error messages when using this inside an anonymous class (#1305)
  • Generate astubx from JSON output of jdk-javac-plugin by @haewiful (#1243)
  • Improve inference for generic method with void-returning lambda argument by @dhruv-agr (#1312)
  • Use refined types from dataflow analysis in generic method inference (#1309)
  • Fail if NullAway is run in JSpecify mode with an incompatible javac version / configuration (#1317)
  • Jdk javac plugin: don't serialize info for classes / methods without annotations by @haewiful (#1316)
  • Maintenance
    • [Cleanup] Refactor away unnecessary Predicate by @lazaroclapp (#1297)
    • Update to Error Prone 2.42.0 (#1299)
    • Update to Gradle 9.1.0 (#1302)
    • Test on JDK 25 (#1301)
    • Compile with JDK 25 (#1303)
    • Add CodeRabbit config (#1306)
    • Update Gradle command used for integration tests (#1311)
    • Disable CodeRabbit review status comments (#1313)
    • Gradle fixes for jar-infer-lib (#1314)
    • Enable building NullAway on JDK 25 (#1315)

NullAway 0.12.10

16 Sep 18:35

Choose a tag to compare

This release contains significant improvements to inference support for generic method calls in JSpecify mode (#1075).
We expect that many more valid calls will pass NullAway, but that some new bugs may have been introduced. Please report
any issues that you see. There is also a new flag, -XepOpt:NullAway:WarnOnGenericInferenceFailure to make NullAway
report a warning when inference fails, to help identify any issues.

  • Improved inference for generic method calls (#1244)
  • Suppress CastToNonNull warnings for @NullUnmarked method calls by @raccoonback (#1258)
  • JSpecify: Fix crash when overriding with raw types (#1265)
  • Better handle calls to super constructors and superclass methods in JSpecify mode (#1248)
  • issue-1250 pattern matching for instanceof in switch case by @dhruv-agr (#1259)
  • Account for annotations in extends / implements when computing view as supertype (#1266)
  • Bug fix with type substitutions after inference (#1277)
  • JSpecify: Improve error messages for type incompatibility at pseudo-assignments (#1279)
  • Support java.util.Objects.toString() by @gulikoza (#1283)
  • Record when generic method inference fails (#1280)
  • issue 1275 - report unboxing warning for for-each loop by @dhruv-agr (#1281)
  • Abstract iterating over invocation arguments (#1284)
  • Invoke generic method inference in more places (#1286)
  • Maintenance
    • Build Spring with snapshot build as a CI job (#1251)
    • Add more instance fields to GenericsChecks (#1256)
    • remove unneeded checkNotCall call (#1257)
    • Fail build on JDK 21 versions before 21.0.8 (#1261)
    • Clarify JDK version to use for best JSpecify support (#1269)
    • Simplified set of CI jobs (#1271)
    • Build: upgrade to Gradle 9 + AGP 8.7.2 (#1270)
    • Compile with JDK 24 (#1276)
    • Don't use deprecated buildDir by @mernst (#1278)

NullAway 0.12.9

18 Aug 18:13

Choose a tag to compare

  • Add a case in our inference for generic method calls (#1240)
  • Add library model for Apache Commons CollectionUtils.isNotEmpty, Amazon CollectionUtils.IsNullOrEmpty, and a couple Amazon StringUtils methods (#1242)
  • Maintenance
    • Fix maven central link in RELEASING.md (#1237)
    • Update to Error Prone 2.41.0 (#1239)
    • Add tests for gh-1246 (#1247)
    • Test reading JSpecify annotations from bytecodes on JDK 21 (#1245)

NullAway 0.12.8

06 Aug 15:38

Choose a tag to compare

  • Document interactions between Guava and JSpecify mode in README (#1208)
  • JSpecify: handle nullness annotations from extends / inherits clauses (#1211)
  • Allowing NewClassTree to be passed into getGenericParameterNullnessAtInvocation (#1210)
  • Support @NullMarked on modules (#1216)
  • Handle NewClassTree in compareGenericTypeParameterNullabilityForCall(#1212) (#1217)
  • More flexible handling of AssertJ isNotNull methods (#1221)
  • Support AssertJ hasSize() (#1229)
  • Inference of generic method type arguments based on returns and parameter passing (#1226)
  • Prototype implementation of javac plugin to serialize nullness annotations (#1225)
  • Add AdditionalSuppressionNames configuration option (#1231)
  • Updates to deploy releases to Central Portal (#1234)
  • Fix to handling of case null (#1235)
  • Maintenance
    • Update to Gradle 8.14 (#1213)
    • Update to Error Prone 2.39.0 (#1228)
    • Fix broken link to Eradicate in README.md (#1227)

NullAway 0.12.7

30 Apr 02:27

Choose a tag to compare

  • Update to Checker Framework 3.49.2 (#1183)
  • Don't check synchronized blocks within unannotated code (#1185)
  • Test on JDK 24 (#1187)
  • Fix multiple issues with NewClassTrees that have enclosing expressions (#1191)
  • Ensure classes null-marked by library model detected in all places (#1197)
  • JSpecify: handle varargs whose element type is a type variable (#1200)
  • Update to Error Prone 2.38.0 (#1203)
  • Optimization to annotation stripping in library model matching (#1204)
  • Make arg position nullness array contents nullable (#1207)
  • Properly handle method references to null-unmarked methods (#1205)

NullAway 0.12.6

27 Mar 21:02

Choose a tag to compare

  • JSpecify: view type as super in generic method inference (#1177)
  • Infer @nullable type arguments for type variables from unmarked code (#1181)
  • Convert android-jar.py to Python 3 (#1175)
  • Suggest castToNonNull fix for unboxing error (#1182)

NullAway 0.12.5

26 Mar 03:24

Choose a tag to compare

  • Add missing override to RestoreNullnessAnnotationsVisitor (#1154)
  • Add more bailouts for raw types (#1153)
  • Do unboxing check for invocation parameters even when calling a @NullUnmarked method (#1163)
  • JSpecify: infer generic method type arguments for assignments (#1131)
  • JSpecify: properly handle lambdas in anonymous inner classes (#1165)
  • Support @MonotonicNonNull on static fields (#1166)
  • Update to Error Prone 2.37.0 (#1169)
  • Use proper name for constructors in JarInfer (#1167)
  • Don't treat @ParametricNullness as @nullable in JSpecify mode (#1174)