ucr-riple / NullAwayAnnotator

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

Annotator is unaware of annotations copied by Lombok in Strict Mode #198

Closed nimakarimipour closed 1 year ago

nimakarimipour commented 1 year ago

Describe the bug In strict mode, Annotator should not make any changes on the target module, that may introduce new errors on downstream dependencies. Although Annotator is aware of possible errors in downstream methods for a generated getter by Lombok (getFoo()), but it is unaware of copying mechanism by Lombok that annotations on foo will get copied on getFoo as well. Hence, it might introduce an error in downstream dependencies.

Expected behavior Annotator should be aware of annotations getting copied on generated getter methods for fields by Lombok. And reject a tree, if any of their getter is creating new errors in downstream dependencies.

Stack trace Not-Applicable.

OS (please complete the following information):

Additional context Not-Applicable.