Add LeakCanary and fix memory leaks in key flows

XMLWordPrintable

    • Type: Task
    • Resolution: Done
    • Priority: Low
    • 2.14
    • Affects Version/s: None
    • None
    • FLW Sprint 54, FLW Sprint 55
    • FLW Mobile App
    • UAT

      A leaked Activity or Fragment keeps its views and bitmaps in memory after the user leaves the screen. That is exactly what Google's background bitmap metric measures. The project has no
      leak detection today.

      Scope:

      • Add debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.14'.
      • Run the main flows on a debug build: login → home → household → registration → forms → sync → incentives.
      • Fix each reported leak. Common causes are uncleared ViewBinding, listeners or Glide targets outliving onDestroyView, and static Context references.

      Acceptance Criteria:

      • [ ] LeakCanary reports no retained Activity or Fragment across the main flows.

              Assignee:
              Ishwar Chouhan
              Reporter:
              Nikhil Ananda Fegade
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: