[ODLPARENT-161] SpotBugs flags errors due to Guava nullable annotations Created: 21/Aug/18  Updated: 14/Sep/18  Resolved: 13/Sep/18

Status: Resolved
Project: odlparent
Component/s: General
Affects Version/s: 4.0.0
Fix Version/s: 4.0.0

Type: Bug Priority: Highest
Reporter: Robert Varga Assignee: Stephen Kitt
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Relates
relates to ODLPARENT-164 Nullable detection should be enabled ... Open

 Description   

As evidenced in https://git.opendaylight.org/gerrit/#/c/75330/ , spotbugs does not understand nullable annotations correctly, reporting:

 

[INFO] --- spotbugs-maven-plugin:3.1.6:check (analyze-compile) @ util ---
[INFO] BugInstance size is 1
[INFO] Error size is 0
[INFO] Total bugs: 1
[ERROR] Null passed for non-null parameter of com.google.common.util.concurrent.Futures.immediateFuture(Object) in org.opendaylight.yangtools.util.concurrent.FluentFutures.<static initializer for FluentFutures>() [org.opendaylight.yangtools.util.concurrent.FluentFutures] At FluentFutures.java:[line 36] NP_NONNULL_PARAM_VIOLATION


 Comments   
Comment by Ariel Adam [ 23/Aug/18 ]

Robert, should this be assigned to you? 

Comment by Robert Varga [ 23/Aug/18 ]

No, I do not have the cycles to look into into. Stephen is aware of this, I suspect he will pick it up before 4.0.0 happens.

Comment by Stephen Kitt [ 28/Aug/18 ]

Forwarded upstream: https://github.com/spotbugs/spotbugs/issues/743

Comment by Stephen Kitt [ 14/Sep/18 ]

To clarify for other readers, this bug is fixed by disabling the relevant warnings (using the same configuration as our FindBugs setup). ODLPARENT-164 requests that these warnings be re-enabled when possible.

Generated at Wed Feb 07 20:27:48 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.