Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable a static code analyzer for null-checking and other common issues #1247

Open
bashir2 opened this issue Nov 19, 2024 · 0 comments
Open
Labels
enhancement New feature or request P2:should An issue to be addressed in a quarter or so.

Comments

@bashir2
Copy link
Collaborator

bashir2 commented Nov 19, 2024

We have experimented with some static code analyzers like SonarQube (e.g., in #704, #706, #707) but these are not adequate, especially for catching NullPointerExceptions. Also we have some @Nullable annotations throughout the code but we don't have a robust null-check static code analyzer that can benefit from these annotations. With release 1.0.0 of Jspecify it makes sense to move our null-check annotations to Jspecify and enable a tool like NullAway on our code. This requires Error Prone which will help catching more issues at compile time.

An early experiment shows over 370 ErrorProne/NullAway warnings, so we should probably fix this issue in multiple phases (e.g., by module).

@bashir2 bashir2 added enhancement New feature or request P2:should An issue to be addressed in a quarter or so. labels Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request P2:should An issue to be addressed in a quarter or so.
Projects
None yet
Development

No branches or pull requests

1 participant