uber / NullAway

A tool to help eliminate NullPointerExceptions (NPEs) in your Java code with low build-time overhead
MIT License
3.63k stars 293 forks source link

Extend library models to mark fields as nullable #878

Closed nimakarimipour closed 10 months ago

nimakarimipour commented 10 months ago

This PR extends LibraryModels to add support for marking fields @Nullable. This feature is required to enable Annotator index impact of making fields @Nullable on downstream dependencies.

Please note, since this feature is mostly going to be used while indexing impacts on downstream dependencies, this PR does not focus on the optimality of the implementation. Also the working set in iterations is not expected to be large. We can optimize the implementation in a follow up PR if needed.

codecov[bot] commented 10 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (5fbee1f) 87.03% compared to head (b16a3a5) 87.10%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #878 +/- ## ============================================ + Coverage 87.03% 87.10% +0.06% - Complexity 1926 1940 +14 ============================================ Files 77 77 Lines 6231 6264 +33 Branches 1212 1218 +6 ============================================ + Hits 5423 5456 +33 Misses 405 405 Partials 403 403 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

nimakarimipour commented 10 months ago

@msridhar Thanks for the review, this is ready for another round. I think it might be better to not land this even after approvals, and land it once I can locally test it with the updates on Annotator.