sentry-java icon indicating copy to clipboard operation
sentry-java copied to clipboard

Add custom lint checks

Open romtsn opened this issue 2 years ago • 1 comments

Description

From the top of my head we could automatically detect the following potential problem that we point out in the PRs all the time:

  • Using withScope instead of configureScope
  • Adding final keywords everywhere (parameters, properties, etc.)
  • Adding @Nullable/@NonNull annotation everywhere (parameters, properties, etc.)
  • Catching Throwable instead of Exception, see #1806

There's probably more, so keep updating this issue when you got something in mind.

romtsn avatar May 02 '23 09:05 romtsn

Let's have a look how much of an effort this is (e.g. using checkstyle for finals, using ? for NotNull/Nullable)

markushi avatar May 03 '23 14:05 markushi