[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: |
|
||||||||
| 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. |