ucr-riple / NullAwayAnnotator

A tool to help adapting code bases to NullAway type system.
MIT License
13 stars 6 forks source link

Update Library Model Loader to mark fields Nullable #220

Closed nimakarimipour closed 11 months ago

nimakarimipour commented 11 months ago

Followup on an update in NullAway recent change #878 which enables NullAway to mark fields as @Nullable. This PR updates our LibraryModelsLoader to enable communication of Annotator and NullAway to mark fields @Nullable while analyzing downstream dependencies. This is required to prepare the code for the upcoming change which enables Annotator to be informed of impacts of making fields @Nullable on downstream dependencies.

nimakarimipour commented 11 months ago

Overall looks good! I have a few comments. Also, why is nullable-methods.tsv checked in as an empty file?

@msridhar Thank you very much for the review, this is ready for another round.

Regarding

Also, why is nullable-methods.tsv checked in as an empty file?

We weren't creating / deleting files in resource directory (which we are now 6dd203e). We used to assume the file exists and clear contents instead of deleting. With the new approach, we no longer need the file.

nimakarimipour commented 11 months ago

@msridhar I don't see the nullable-methods.tsv file on my branch. Isn't this PR actually deleting the existing nullable-methods.tsv on master branch ? Please let me know if I am missing something.

msridhar commented 11 months ago

@msridhar I don't see the nullable-methods.tsv file on my branch. Isn't this PR actually deleting the existing nullable-methods.tsv on master branch ? Please let me know if I am missing something.

Yes, you're right. For some reason GitHub shows the change strangely. Locally git shows the file as removed. Sorry for the confusion.

nimakarimipour commented 11 months ago

@msridhar Ok great, will land this one now and update #221.