RxLint, the lint check that helps you to write better RxJava code, has been updated with a couple of important changes.

  • RxLint now supports both RxJava 2.x in addition to 1.x. All reactive types for both versions are now fully supported (Support for the 1.x Completable was still missing).
  • A new check has been added to detect a “leaked” subscription. Leaking a subscription happens when you use subcribe() or subscribeWith() without capturing the Subscription or Disposable object in a variable. Not keeping a reference prevents you to call unsubscribe() or dispose() to unsubscribe which can lead to bugs and memory leaks.

In addition, the lint check has been rewritten to use the newer Psi-style lint check, so it is fully up to date with the current build tools again.

Using RxLint in your project is easy: just add the RxLint dependency to your project.

Happy linting!