Skip to content
CAI
Software that uses CAICheck a score

square/leakcanary

65.0

Adequate · 22 September 2026

65.4k

lines of production code

Kotlin

primary language

5

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a comprehensive Android memory leak detection and analysis platform, comprising the LeakCanary library for runtime detection and the Shark engine for deep heap dump analysis. It provides capabilities to automatically monitor object retention, capture and process HPROF files, and visualize memory leaks through both a dedicated desktop application and command-line tools. The system also supports integration into automated test suites and release builds, offering robust APIs for detecting leaks in production and development environments.

How it got here

2015–2023 — LeakCanary 3.0 and Shark modernization

62 changes.

This period focused on the major architectural overhaul of LeakCanary for version 3.0, introducing a modular design with automatic initialization, separate-process heap analysis, and a new Material 3 UI. Concurrently, the Shark heap analysis engine was significantly refactored to support large dumps, concurrent reading, and precise Android-specific leak detection, while establishing stable public APIs for both the core library and its Gradle plugins.

2024–2026 — Shark Dive and test infrastructure expansion

21 changes.

This period focused on launching the Shark Dive application for visual heap dump analysis and integrating AI agent support via the Model Context Protocol. Simultaneously, the project significantly expanded its testing capabilities by introducing comprehensive in-process heap growth detection utilities for JVM, Android, and UI Automator environments, alongside robust storage strategies and OOM guidance.

Features

Add LeakCanary process sample app

A new sample application has been added to demonstrate heap analysis within a separate \:leakcanary\ process. The app includes a main activity that intentionally leaks itself when a button is tapped, allowing users to verify that LeakCanary correctly detects and reports memory leaks in multi-process Android environments.

samples/leakcanary-android-process-sample · high confidence

Add UI Automator heap dump utilities and shell-based dumping support

This change introduces new utilities in the \leakcanary-android-uiautomator\ module to support heap analysis within Android UI Automator tests. It adds \UiAutomatorShellHeapDumper\ to perform heap dumps via shell commands (including optional GC on API 27+), \UiAutomatorShellFileDeleter\ for cleaning up dump files, and \AndroidDeviceTempHeapDumpDirectoryProvider\ for managing temporary storage. These components are wired into \RepeatingUiAutomatorScenario\, enabling object growth detection in UI tests by leveraging the \shark\ library's \RepeatingScenarioObjectGrowthDetector\ with proper hprof handling and deletion strategies.

leakcanary/leakcanary-android-uiautomator/src/main/java · high confidence

Add synthetic heap dump generation capability for testing

The \shark-hprof-test\ module now includes a new \HprofWriterHelper\ class that enables the programmatic creation of synthetic HPROF heap dump files. This utility allows tests to write specific object graphs, including classes like \KeyedWeakReference\ and primitive arrays, into a valid heap dump structure, facilitating more controlled and repeatable testing of heap analysis logic without relying on real-world memory dumps.

shark-hprof-test · high confidence

Enable heap dump analysis in release builds

The release build variant now includes a dedicated application class that activates LeakCanary's heap analysis capabilities. This change allows users to capture and analyze memory leaks in release builds by configuring the app to store heap dumps in the no-backup directory, logging analysis results to the logcat, and triggering analysis both on background execution and when the screen turns off.

samples/leakcanary-android-sample/src/release · high confidence

Initial database schema for tracking heap analysis leaks

This change introduces the core database schema for LeakCanary's app database, defining tables for applications, heap analyses, leaks, and leak traces. It establishes the data model used to store and query memory leak information, including fields for leak fingerprints, descriptions, and read statuses, along with the necessary SQL queries for inserting, selecting, and updating this data.

leakcanary/leakcanary-app-db · high confidence

Initial public API and core object-watcher implementation

This change introduces the foundational public API and core implementation for the object-watcher module. It defines the \ObjectWatcher\ class and associated interfaces (\InstallableWatcher\, \ReachabilityWatcher\, \DeletableObjectReporter\) that allow the library to track object reachability and detect retained objects. The diff includes the initial \.api\ files for \object-watcher\, \object-watcher-android\, \object-watcher-android-core\, and \object-watcher-android-startup\, establishing the public contract. It also adds the \ReferenceQueueRetainedObjectTracker\ implementation, which uses Java's \ReferenceQueue\ to monitor object lifecycles, and configures ProGuard rules to preserve reflection-dependent classes like \AndroidXFragmentDestroyWatcher\ and \ViewModelStore\. Additionally, detekt baselines are added to suppress specific style issues in the new code.

object-watcher · high confidence

Initial repository structure and documentation site setup

The repository is initialized with the core project scaffolding, including a README, Apache 2.0 license, and a Gradle wrapper. The documentation site is configured using MkDocs with the Material theme, providing a structured navigation for LeakCanary and Shark. Additionally, developer guidelines are established through AGENTS.md and CLAUDE.md, and repository hygiene is enforced via .editorconfig and .gitattributes.

(repo-wide) · high confidence

Introduce JDWP-based heap dump support for older Android devices

Shark Dive now supports heap analysis on Android devices below API 27 by attaching to the target process via JDWP to trigger garbage collection and extract bitmap images, filling the gap where the native \am dumpheap -g\ command is unavailable. This change adds \JdwpGc\ to invoke \Runtime.gc()\ and \System.runFinalization()\ within the app process to ensure a clean heap state, and \JdwpBitmaps\ to compress live bitmap pixels into PNGs via the JDWP interface, allowing memory leak investigation on older hardware without requiring root or NDK agents. The module also includes a new evaluation framework (\EvalScenarios\) to test agent accuracy against synthetic and real-world heap dumps.

shark-dive-eval, shark-dive-jdwp, shark/shark-dive/shark-dive-jdwp · high confidence

Introduce Shark CLI with heap analysis and growth detection commands

The shark CLI tool is now available, providing a suite of commands for heap dump analysis. Users can run \analyze\ to detect leaks, \heap-growth\ to monitor memory growth over time (supporting both live device dumps and directory-based hprof files), and \interactive\ to explore heap dumps via a console. Additional utilities include \dump-process\ to pull heap dumps from running Android processes (with automatic garbage collection on Android 8.1+), \deobfuscate-hprof\ to resolve ProGuard mappings, and \strip-hprof\ to remove sensitive primitive data from heap dumps. The CLI also supports verbose logging and handles gzipped heap dumps natively.

shark/shark-cli · high confidence

Introduce Shark Dive app with heap visualization, leak detection, and agent integration

The Shark Dive application is now available, providing a new interface for analyzing Java heap dumps. Users can visualize heap structures using three distinct layout modes: Treemap, Radial, and Stack. The app includes a color-coding system based on reachability strength (e.g., Strong, Weak, Unreachable) and supports leak detection, allowing users to identify objects that should not be in memory. A details panel provides in-depth information about selected objects, including retained size and class details. The application also supports deep linking for navigation between heap dumps and integrates with external agents via a dedicated socket, enabling remote investigation and automated analysis. Command-line arguments allow for custom window titles and deep link handling.

shark-dive-app · high confidence

Introduce Shark Dive core library with heap analysis and deep linking

This change introduces the core logic for the Shark Dive application, replacing the previous 'Shark Explorer' branding. It adds a new \Adb\ abstraction for managing Android device connections and heap dump retrieval, and a \DeepLink\ system that allows users to share and open specific views (such as leaks, object lists, or starred items) via \shark://\ URIs. The module also implements \HeapDive\ to open and index \.hprof\ files, calculating reachability and dominator trees, and includes \HeapBitmaps\ to extract and display bitmap images from heap dumps across different Android API levels.

shark-dive-core · high confidence

Introduce new HprofReader and HprofWriter components

The shark-hprof module now includes new classes for reading and writing hprof files. HprofReader provides a streaming API for parsing hprof files, while HprofWriter allows generating hprof files. These components support various hprof record types including class dumps, instance dumps, and primitive array dumps.

shark-hprof · high confidence

Introduces an MCP server surface for AI agent investigation of heap dumps

Shark Dive now exposes an Model Context Protocol (MCP) server that allows external AI agents to investigate heap dumps currently open in the application window. This new \shark-dive-agent\ module provides a set of tools (such as \list\_leaks\, \chain\_from\_gc\_root\, and \set\_verdict\) that enable an agent to navigate the heap, analyze reference chains, and record verdicts, while strictly enforcing a structured investigation method. The implementation includes a session logging system that records every agent call, refusal, and outcome to disk for later review, and supports multiple connection modes including standard MCP stdio and a command-line interface for manual testing.

shark/shark-dive/shark-dive-app · high confidence

Introduces configurable heap analysis and ProGuard mapping support for release builds

This change adds the core configuration and execution infrastructure for heap analysis in release builds. It introduces \HeapAnalysisConfig\ to allow customization of reference matchers, object inspectors, and metadata extraction, and adds a \proguardMappingProvider\ to enable proper symbolication of leak traces in minified builds. The new \HeapAnalysisJob\ interface and its \RealHeapAnalysisJob\ implementation manage the lifecycle of analysis tasks, including support for interceptors and a \JobContext\ for passing data between steps. Additionally, the \stripHeapDump\ configuration option is now supported, allowing users to zero out sensitive array data in heap dumps to protect privacy, with the stripping duration reported in the analysis metadata.

leakcanary-android-release · high confidence

Introduces thread-safe heap graph API with cancellation support

The \shark-graph\ module now exposes a new \HeapGraph\ interface and its \CloseableHeapGraph\ implementation, enabling safe concurrent reads from multiple threads. This update adds a \GraphContext\ for thread-safe in-memory storage associated with a graph instance, and integrates a \CancelSignal\ that allows long-running heap dump analyses to be stopped mid-read. Additionally, the API now exposes JVM thread dumps (stack traces) from HPROF files via the \threads\ property, which are available for Java heap dumps but empty for Android ones.

shark/shark-graph/src/main/java/shark · high confidence

LeakCanary now runs heap analysis in a separate process

The \leakcanary-android-process\ module introduces a new \LeakCanaryProcess\ API and a \RemoteLeakCanaryWorkerService\ that enables LeakCanary to perform heap analysis in a dedicated background process (\:leakcanary\) rather than the main app process. This separation prevents the analysis from interfering with the app's main thread and UI. The module also ships necessary ProGuard keep rules for WorkManager components to ensure compatibility with minified builds, and provides a public method to detect if the current code is running inside the analyzer process.

leakcanary/leakcanary-android-process · high confidence

LeakCanary sample app adds Android TV support and new leak scenarios

The sample application now supports Android TV by declaring leanback features and adding the LEANBACK\_LAUNCHER intent category to the main activity. The UI has been updated with new buttons to demonstrate additional memory leak patterns, including service leaks, broadcast receiver leaks, message handler leaks, and infinite animator leaks, alongside the existing activity and dialog leak demonstrations.

samples/leakcanary-android-sample/src/main · high confidence

New Gradle plugin for copying obfuscation mapping files to assets

A new Gradle plugin (\leakcanary-deobfuscation-gradle-plugin\) has been added to allow users to automatically copy ProGuard/R8 obfuscation mapping files into the APK's assets directory. By configuring the \leakCanary\ extension's \filterObfuscatedVariants\ function, developers can specify which build variants should have their mapping files included, enabling LeakCanary to display readable stack traces for obfuscated builds.

leakcanary/leakcanary-deobfuscation-gradle-plugin/src/main · high confidence

New JVM in-process heap dump and growth detection utilities

This change introduces new components for detecting object growth in JVM in-process tests. It adds HotSpotHeapDumper to capture heap dumps using HotSpot Diagnostic MXBeans, RepositoryRootHeapDumpDirectoryProvider to locate heap dump directories relative to the repository root, and a new repeatingJvmInProcessScenario helper that orchestrates these tools with in-process GC triggers and warmup capabilities for accurate heap growth analysis.

leakcanary/leakcanary-jvm-test/src/main · high confidence

New LeakCanary UIAutomator integration artifacts

This change introduces a new \leakcanary-android-uiautomator\ module, exposing public APIs for integrating LeakCanary with UIAutomator tests. The new library provides \UiAutomatorShellHeapDumper\ for capturing heap dumps via shell commands, \UiAutomatorShellFileDeleter\ for cleanup, \AndroidDeviceTempHeapDumpDirectoryProvider\ for managing temporary storage on the device, and a \repeatingUiAutomatorScenario\ helper to automate object growth detection in UI tests. It also includes the \HeapDumpStorageStrategy\ interface (renamed from \HeapDumpDeletionStrategy\), which is used by the new scenario helper to manage heap dump lifecycle.

leakcanary/leakcanary-android-uiautomator · high confidence

New Neo4j database export command for heap dumps

The Shark CLI now includes a new 'neo4j' command that converts Android heap dumps into a local, embedded Neo4j graph database. This allows users to analyze memory leaks using Cypher queries via the GraphApp browser, with the database stored in a local directory and the embedded server automatically shut down after the session.

shark-cli · high confidence

New Shark Dive Agent surface for automated heap dump investigation

Shark Dive now exposes an agent interface that allows automated clients to investigate heap dumps using the Model Context Protocol (MCP) or a command-line adapter. This adds a suite of tools—including listing leaks, describing objects, tracing GC roots, and setting verdicts—enabling agents to perform investigations that are logged in the \Agent logs\ screen. The implementation includes an stdio bridge for standard MCP client integration and a command-line tool for direct tool invocation, with all agent activity recorded in session files for traceability and evaluation.

shark-dive-agent · high confidence

New TestDescriptionHolder rule for capturing test context

A new JUnit TestRule, TestDescriptionHolder, has been added to the test-core module. This rule automatically captures the current test's Description in a thread-local variable during execution, allowing test code to retrieve the specific test context via the testDescription property. This capability supports the updated API iteration used in Square's unit tests by providing a reliable way to access test metadata from within the test thread.

leakcanary-test-core · high confidence

New app navigation and screen structure for leak analysis

The app introduces a new navigation architecture and UI screens for viewing leak data. A new BackStackViewModel manages the navigation state, allowing users to move between screens such as the Client Apps list, Client App Analyses, individual Analysis details, and specific Leak traces. The UI now displays client apps with their leak counts, lists analyses for each app, and presents detailed leak information including leak traces and options to share or print the analysis.

leakcanary-app · high confidence

New instrumentation API for asserting no memory leaks

The leakcanary-android-instrumentation module now exposes a new \LeakAssertions\ object, providing an \assertNoLeaks\ method for use in instrumentation tests. This allows developers to programmatically verify that no memory leaks exist in the heap at a specific point in their test execution, failing the test if leaks are detected. The underlying \InstrumentationHeapAnalyzer\ has been added to handle the heap dump analysis, including logging analysis progress and appending file I/O statistics to the analysis metadata.

leakcanary-android-instrumentation · high confidence

New instrumentation test leak detection API

LeakCanary now provides a new set of APIs for detecting memory leaks in Android instrumentation tests. This includes the \DetectLeaksAfterTestSuccess\ JUnit rule, which automatically runs leak analysis after a test passes, and the \SkipLeakDetection\ annotation to selectively bypass checks. The implementation introduces a configurable \DetectLeaksAssert\ interface and an \AndroidDetectLeaksInterceptor\ that manages the timing of heap dumps (including idle waits and GC triggers) to improve accuracy. Additionally, a \RetryingHeapAnalyzer\ is used to handle potential heap dump corruption by automatically retrying the analysis once if the first attempt fails.

leakcanary/leakcanary-android-instrumentation/src/main/java · high confidence

New leakcanary-android-utils module provides Android-specific heap dumping and logging utilities

A new \leakcanary-android-utils\ module has been introduced, extracting Android-specific utilities from the core library. This module exposes \AndroidDebugHeapDumper\ for dumping the Android heap via \Debug.dumpHprofData\ and \LogcatSharkLog\ to route LeakCanary's internal logging to Android's Logcat. It also includes internal helpers for main-thread checks, timing measurements, and object delegation, making these capabilities available as a separate dependency.

leakcanary/leakcanary-android-utils · high confidence

New public API for detecting memory leaks in Android instrumentation tests

Leakcanary now exposes a dedicated set of classes and interfaces for asserting memory leak detection within Android instrumentation tests. This includes the \DetectLeaksAfterTestSuccess\ JUnit rule for automatic post-test checks, \AndroidDetectLeaksAssert\ for verifying specific heap analysis results, and the \SkipLeakDetection\ annotation to selectively bypass leak checks on individual tests. These additions provide a structured, public API for integrating leak detection into Android test suites, replacing or supplementing previous internal mechanisms.

leakcanary/leakcanary-android-instrumentation · high confidence

New test utilities and centralized logging for Shark

This change introduces a centralized logging mechanism via the new \SharkLog\ object, allowing users to configure a global logger for debug messages and exceptions across Shark artifacts. It also adds test infrastructure: a \HeapDumpRule\ JUnit rule for capturing heap dumps during tests, a \JvmTestHeapDumper\ utility to trigger heap dumps via HotSpot MXBeans, and a \ProguardMappingHelper\ to simplify creating Proguard mappings in tests. Additionally, detekt baselines are added to suppress specific style issues in the new and existing test files.

shark/shark-hprof-test, shark/shark-log, shark/shark-test · high confidence

Support for JVM HPROF thread dumps and large heap dumps

Shark now reconstructs and exposes thread stacks from JVM HPROF heap dumps via the new HeapThread and HeapStackFrame APIs, allowing users to analyze thread states alongside heap objects. To handle extremely large heap dumps that exceed the JVM's single-array size limit, the internal indexing system has been refactored to use paged byte arrays (PagedByteArray, PagedSortedBytesMap), enabling the storage of indexes larger than 2 GB. Additionally, the library now supports reporting and processing record and object sizes larger than 2 GB, and ensures thread-safe reading of heap graphs from multiple concurrent threads.

shark-graph · high confidence

Test utilities for automatic heap dump naming based on test identity

The leakcanary-test-core module now includes test support classes that allow heap dumps to be automatically named after the running test. A new TestNameProvider detects the current test's class and method name (via JUnit's Description or stack trace inspection), and TestHeapDumpFileProvider uses this information to generate heap dump files with descriptive names (e.g., \_ClassName-methodName) instead of generic timestamps. This helps users quickly identify which test triggered a leak during unit testing.

leakcanary/leakcanary-test-core · high confidence

API

LeakCanary Deobfuscation Gradle Plugin API and Baseline Added

The public API for the \leakcanary-deobfuscation-gradle-plugin\ is now explicitly defined, exposing the \CopyObfuscationMappingFileTask\ for handling mapping file operations, the \LeakCanaryDeobfuscationExtension\ for configuring variant filtering, and the \LeakCanaryLeakDeobfuscationPlugin\ entry point. Additionally, a detekt baseline file has been introduced to suppress specific code style issues, such as unused imports, ensuring consistent static analysis for the plugin.

leakcanary/leakcanary-deobfuscation-gradle-plugin · high confidence

New public API for heap dump storage strategies and warmup detection

LeakCanary now exposes a new public API surface in leakcanary-core, introducing the HeapDumpStorageStrategy interface with implementations for deleting, keeping, or keeping zipped heap dumps based on object growth. It also adds the DatetimeFormattedHeapDumpFileProvider for timestamped dump filenames, the HeapDumpDirectoryProvider and HeapDumper interfaces, and utilities like ObjectGrowthWarmupHeapDumper to support proper warmup handling during heap growth detection.

leakcanary/leakcanary-core/api · high confidence

Shark API surface update with new size handling and reference readers

The public API for the Shark library has been updated to include new classes for handling Android-specific heap analysis, such as \AndroidNativeSizeMapper\ and \AndroidObjectSizeCalculator\, alongside expanded reference reader implementations like \ChainingInstanceReferenceReader\ and \FilteringLeakingObjectFinder\. The \ByteSize\ class now exposes methods for converting to whole gigabytes, megabytes, and kilobytes, and the \ApplicationLeak\ class exposes a \getLeakFingerprint\ method, reflecting changes in how leak signatures and retained sizes are reported.

shark/shark/api · high confidence

Shark Hprof API stability contract and cancellation support

This change establishes the public API surface for the shark-hprof module, introducing a formal stability contract via the new \shark-hprof.api\ file. It exposes core classes for heap dump processing, including \HprofHeader\ for parsing dump metadata, \HprofPrimitiveArrayStripper\ for optimizing memory usage, and \HprofDeobfuscator\ for mapping symbols. A key behavioral addition is the introduction of \CancelSignal\ and \CancelableSourceProvider\, allowing users to interrupt long-running heap dump reads and processing tasks. The API also defines various \GcRoot\ subtypes to represent different garbage collection root categories and provides source providers like \ByteArraySourceProvider\ and \FileSourceProvider\ for flexible input handling.

shark/shark-hprof/api · high confidence

Behavioural changes

Added Android framework leak fixes and window callback compatibility

The plumber-android-core module now includes built-in mitigations for known Android framework memory leaks, such as clearing the TextLine pool, handling UserManager context retention, and flushing HandlerThread references on older Android versions. Additionally, a FixedWindowCallback implementation is introduced to prevent runtime crashes caused by non-nullable menu parameters in onMenuOpened, ensuring compatibility with specific Android framework behaviors.

plumber-android-core · high confidence

Added build configuration files for ProGuard, lint, and detekt

The leakcanary-android-core module now includes configuration files to support build-time tooling: a ProGuard rules file to preserve internal classes used by reflection and suppress warnings for removed Android APIs, a lint configuration to ignore specific internationalization checks, and a detekt baseline to suppress existing code style issues.

leakcanary/leakcanary-android-core · high confidence

Automatic startup initialization for Object Watcher and Plumber leak fixes

LeakCanary now automatically initializes the Object Watcher and Plumber (Android leak fixes) modules on application startup, removing the need for manual setup in most cases. The Object Watcher is now installed via an \AppWatcherStartupInitializer\ using AndroidX Startup, while Plumber's leak fixes (such as clearing the \ViewLocationHolder\ static pool and fixing \InputMethodManager\ leaks) are applied automatically via a \PlumberInstaller\ content provider. This behavior is controlled by new boolean flags (\leak\_canary\_watcher\_auto\_install\ and \leak\_canary\_plumber\_auto\_install\) which default to true, allowing users to disable automatic installation if needed.

(repo-wide) · high confidence

Database access now uses dedicated dispatchers with Write-Ahead Logging support

The app's data layer now explicitly manages database threading via a new \DatabaseDispatchers\ interface and Hilt module. Reads and writes are routed to separate coroutine dispatchers: when Write-Ahead Logging (WAL) is enabled (on non-low-RAM devices), multiple threads handle reads while a single thread handles writes; otherwise, a single thread handles both. This change improves concurrency for database operations in the \HeapRepository\ and ensures the SQLite driver is configured with WAL support where appropriate.

leakcanary/leakcanary-app/src/main/java/org/leakcanary/data · high confidence

Enforce static analysis via pre-push hook and detekt configuration

A new pre-push Git hook has been added to automatically run the Detekt static analysis tool before allowing code pushes, blocking commits if violations are found. This is supported by a new \config/detekt-config.yml\ file that defines the analysis rules, including specific thresholds for complexity and class size tailored for the project's needs.

config · high confidence

Expanded Android leak detection matchers and inspectors

The Android leak detection API now includes a significantly larger set of built-in reference matchers and object inspectors to identify memory leaks in Android-specific components. This update adds matchers for various system services (such as UiModeManager, PermissionControllerManager, and InputMethodManager), third-party libraries (like Flipper), and device manufacturer-specific issues (including Infinix, Lenovo, and Sharp). It also introduces new object inspectors for Android framework classes like ActivityThread, Loader, and Toast, allowing the tool to more accurately detect and report leaks in these areas.

shark/shark-android/api · high confidence

Heap analysis now runs in a background process with reliable event dispatch

LeakCanary now performs heap analysis in a separate \:leakcanary\ process using \HeapAnalyzerWorker\ and \HeapAnalysisDoneDispatchWorker\ to ensure the analysis result is reliably dispatched to the main process even if the app crashes during the operation. The \AndroidDebugHeapAnalyzer\ handles the actual analysis and stores results in the local database, while the \HeapDumpTrigger\ and \HeapDumpControl\ manage the decision to dump and the conditions under which it is allowed (e.g., debugger status, test mode). Additionally, the leak trace UI now supports multiline squiggly underlines for better readability of long reference paths.

leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal · high confidence

Heap dumps now stored in app's private no-backup directory

LeakCanary no longer requires external storage permissions and stores heap dumps in the app's private no-backup directory instead of the public Downloads folder. This change ensures heap dumps are never visible to other apps, are not deleted by the system when storage is low, and do not count against the user's Android Auto Backup quota. The \requestWriteExternalStoragePermission\ configuration option is now deprecated and has no effect.

leakcanary-android-core · high confidence

Heap graph analysis performance and stability improvements

The internal heap graph implementation has been refactored to significantly improve memory efficiency and concurrency. A new bit-vector-based set (HeapObjectIdSet) replaces hash-based sets for tracking visited objects, reducing memory overhead from \~10.7 bytes per object to 1 bit per object, which prevents out-of-memory errors on large Android heaps. Indexes for oversized per-record-type data are now sharded across paged byte arrays to bypass the JVM's 2 GB single-array limit, utilizing a custom paged TimSort for in-place sorting. Additionally, field value reading is now thread-safe by using per-call reader instances that advance a local position, and object lookups are keyed by dense indices rather than raw IDs to optimize access patterns.

shark/shark-graph/src/main/java/shark/internal · high confidence

Improved Android heap analysis with OEM-specific leak detection and metadata extraction

Shark now extracts detailed Android metadata (manufacturer, SDK version, process name, bitmap stats) from heap dumps to enable precise, version- and OEM-specific leak detection. This includes filtering known Android framework leaks (e.g., PermissionControllerManager on API 29+, ActivityThread.mNewActivities on API 19+) and manufacturer-specific static context leaks (Motorola, NFINIX, LENOVO). It also adds new reference matchers to ignore non-leaking growth patterns like BinderProxy on API 34+ and Compose TestContext states, and improves fragment lifecycle detection by forking behavior based on the androidx.fragment version (1.0.0 vs 1.1.0+).

shark/shark-android/src/main · high confidence

Improved fragment lifecycle monitoring for AndroidX

The AndroidX fragment watcher now correctly handles fragment instance reuse introduced in androidx.fragment 1.1.0, preventing false retention reports for fragments that are destroyed and re-added within the same transaction. It also includes a ViewModelClearedWatcher that monitors ViewModel lifecycle events to ensure they are properly tracked for deletion.

object-watcher/object-watcher-android-androidx · high confidence

Improved heap dump handling and OOM guidance for Android instrumentation tests

This update introduces new utilities for Android instrumentation tests to improve reliability and debugging. Heap dumps are now stored in the app's no-backup directory via the new \TargetContextHeapDumpDirectoryProvider\, ensuring they are excluded from Android Auto Backup and require no special permissions. Additionally, the library now reads the Android heap limit directly from the app under test's manifest using \AndroidTestHeapLimit\, providing users with specific, actionable guidance in Out Of Memory failure messages (e.g., clarifying if \android:largeHeap="true"\ is missing or incorrectly placed in the test APK manifest). A new \RepeatingAndroidInProcessScenario\ helper simplifies setting up repeating object growth detectors for in-process tests like Espresso, and the \HeapDumpDeletionStrategy\ has been renamed to \HeapDumpStorageStrategy\.

leakcanary/leakcanary-android-test/src/main · high confidence

Improved heap graph traversal and retained size accuracy

Shark now uses specialized virtual reference readers to traverse Android and Java data structures (such as ActivityThread.mNewActivities, MessageQueue, and Apache Harmony collections) directly, flattening internal nodes to prevent duplicate growth reports and ensure accurate retained size calculations. It also adds support for mapping native allocation sizes via NativeAllocationRegistry$CleanerThunk, allowing the total object size to include native memory, and introduces a ByteSize value class for clearer size representation.

shark/shark/src/main/java/shark · high confidence

Improved heap growth detection with warmup, storage strategies, and OOM guidance

Heap growth detection in automated tests is now more robust and user-friendly. A warmup phase using embedded heap dump data ensures the object growth detector initializes correctly before real dumps are analyzed, preventing false positives or failures in JUnit tests. The system now offers configurable storage strategies (DeleteOnHeapDumpClose, KeepHeapDumps, KeepHeapDumpsOnObjectsGrowing, and KeepZippedHeapDumpsOnObjectsGrowing) to manage disk space and retain dumps for debugging when leaks are found. Additionally, if heap growth detection runs out of memory, users receive specific guidance on how to increase the heap limit (via -Xmx for JVM or android:largeHeap for Android) or switch to analyzing dumps on a local machine using shark-cli.

leakcanary/leakcanary-core · high confidence

Improved memory leak detection for Android Views and Activities

The AndroidObjectInspectors module now includes specific heuristics to accurately detect memory leaks in Android Views and Activities. For Views, it identifies leaks when a root view is detached from the window hierarchy but still holds a reference to a destroyed activity context, or when a DecorView is detached after being attached. It also handles edge cases where views are mocked by Mockito (resulting in null context) to prevent false positives. For Activities, it flags instances as leaking if the activity's mDestroyed flag is true, ensuring that destroyed activities retained in memory are correctly reported.

shark-android · high confidence

Introduce modular Android object-watcher core with auto-installation

The object-watcher-android-core module now provides a structured, modular entry point for Android memory-leak detection. AppWatcher serves as the main API, automatically installing a suite of watchers (ActivityWatcher, FragmentAndViewModelWatcher, RootViewWatcher, and ServiceWatcher) on app startup to expect objects to become weakly reachable after their lifecycle callbacks (onDestroy, onCleared, onDetachedFromWindow). Developers can customize this behavior by disabling auto-installation via the leak\_canary\_watcher\_auto\_install resource and calling AppWatcher.manualInstall() with a custom list of watchers or a retained delay. The ServiceWatcher implementation has been refactored to use a Handler.post mechanism for detecting service destruction, and the FragmentAndViewModelWatcher now dynamically supports AndroidX, Android Support Library, and native Android O+ fragments. A new resource, leak\_canary\_watcher\_watch\_dismissed\_dialogs, allows controlling whether dismissed dialogs are watched for leaks.

object-watcher/object-watcher-android-core · high confidence

LeakCanary Android Core API surface stabilized

The public API for the leakcanary-android-core module has been defined and stabilized, exposing the core configuration options via LeakCanary.Config and its Builder, as well as a comprehensive event-driven listener system (EventListener) for monitoring heap dump and analysis lifecycle events. This change establishes the official contract for integrating with LeakCanary's core analysis engine, including support for various event listeners like Logcat, Notification, Toast, and WorkManager-based analyzers, while removing previously deprecated APIs to simplify the developer experience.

leakcanary/leakcanary-android-core/api · high confidence

LeakCanary app introduces Material 3 theming and utility infrastructure

The LeakCanary application now features a modernized user interface with Material 3 support, including dynamic color theming for Android 12+ devices and a defined color palette (purple, pink, and grey tones) for light and dark modes. This visual update is supported by new internal utilities: a thread-safe activity provider for UI interactions, a sharer component to export leak traces via the system share sheet, a leak trace wrapper for proper text wrapping in reports, and helpers for serialization and relative time formatting.

(repo-wide) · high confidence

LeakCanary app restructured with new UI and service architecture

The LeakCanary application has been reorganized to focus on sending hprof files, removing previous AIDL dependencies in favor of a new service-based approach. The app now features a Compose-based UI with a theme system and a backstack navigation model, initialized via a new Application class that registers activity lifecycle callbacks. A new background service, LeakUiAppService, handles incoming heap analysis data by copying heap dumps to local storage and persisting them via the HeapRepository, enabling the app to receive and process memory leak reports from other applications.

leakcanary/leakcanary-app/src/main/java/org/leakcanary · high confidence

New Android leak fixes and startup initializer exposed in public API

The library now exposes a new \AndroidLeakFixes\ enum and companion object in \plumber-android-core\, allowing users to apply specific known Android framework leaks (such as \PERMISSION\_CONTROLLER\_MANAGER\ and \VIEW\_LOCATION\_HOLDER\) via the \applyFixes\ method. Additionally, \plumber-android-startup\ introduces a \PlumberStartupInitializer\ to enable automatic initialization via AndroidX Startup, while ProGuard rules are added to preserve the reflective access required for the leak fix enum.

plumber · high confidence

New in-process GC trigger with Android Studio compatibility

LeakCanary now uses a new default garbage collection strategy that runs finalization before heap dumping, matching Android's internal behavior to improve detection accuracy. To ensure Android Studio's Profiler continues to work via its reflective bridge, the library maintains backward compatibility by keeping the legacy \GcTrigger$Default\ class name, which now delegates to the new \FinalizingInProcessGcTrigger\.

leakcanary/leakcanary-gc · high confidence

New navigation structure and screen host for LeakCanary app

The app introduces a new navigation architecture with a \Destination\ sealed class defining specific screens for Client Apps, Client App Analyses, Leaks, and individual Leaks (identified by a leak fingerprint). A new \ScreenHost\ composable manages the navigation stack, providing a top app bar with back navigation and horizontal slide animations when transitioning between these screens. This change reorganizes the app's UI flow to better group related leak analysis data.

leakcanary/leakcanary-app/src/main/java/org/leakcanary/screens · high confidence

New release-specific leak analysis triggers and resource-saving interceptors

The release build of LeakCanary now includes dedicated triggers and interceptors to manage heap analysis in production. BackgroundTrigger and ScreenOffTrigger allow analysis to run when the app enters the background or the screen turns off, with the latter updated to use RECEIVER\_EXPORTED flags on Android 13+ to prevent ANRs. Several interceptors (MinimumDiskSpace, MinimumMemory, MinimumElapsedSinceStart, OncePerPeriod, GoodAndroidVersion, SaveResourceIds) are introduced to prevent analysis on low-resource devices, respect time periods, and handle Android version-specific issues, ensuring the library behaves safely in release environments.

leakcanary/leakcanary-android-release · high confidence

Refactored event handling and heap analysis execution paths

LeakCanary now uses a modular event-listener architecture to handle heap dumps and analysis results, introducing dedicated components for different execution contexts and user feedback mechanisms. The library now supports running heap analysis in a separate process via WorkManager (RemoteWorkManagerHeapAnalyzer) to improve stability, while also offering a background-thread option (BackgroundThreadHeapAnalyzer) for simpler setups. User notifications are now handled by specific listeners: NotificationEventListener manages standard push notifications, ToastEventListener displays blocking toasts during heap dumps, LogcatEventListener prints detailed progress and results to the console, and TvEventListener provides Android TV-specific feedback via toasts and ADB launch instructions. This refactoring isolates concerns, allowing the library to adapt its behavior based on the available Android APIs and process boundaries.

leakcanary/leakcanary-android-core/src/main/java/leakcanary · high confidence

Refactored internal heap analysis infrastructure and reference readers

The internal \shark\ module has been reorganized with new helper classes and readers to improve heap dump analysis. \FieldIdReader\ now handles ID parsing for various byte sizes, while \QueuedNode\ optimizes the path-finding traversal by using object indices instead of IDs to reduce memory usage. Reference readers for collections like \WeakHashMap\ and \ArrayList\ have been enhanced to provide more detailed leak trace information, including specific entry keys. Additionally, \ShallowSizeCalculator\ has been updated to more accurately account for the size of \String\ and primitive wrapper arrays, and error reporting for invalid object IDs now includes the full reference path to aid in debugging.

shark/shark/src/main/java/shark/internal · high confidence

Refactored object reachability tracking with new functional interfaces

The object-watcher module has been restructured to use new functional interfaces for tracking object reachability, specifically introducing DeletableObjectReporter, TriggeredDeletableObjectReporter, and RetainedObjectTracker to replace the previous ReachabilityWatcher and ObjectWatcher patterns. This change modernizes the API by leveraging Kotlin fun interfaces, allowing callers to pass lambda expressions directly for behaviors like reporting deletable objects or listening to retention events. The legacy ObjectWatcher class is now deprecated in favor of these new interfaces, and supporting components like UptimeClock and DelayedExecutor have been added to abstract time sources and execution delays, providing a more flexible and testable foundation for leak detection logic.

object-watcher/object-watcher/src/main · high confidence

Sample app refactored to use new low-level LeakCanary assembly APIs

The leakcanary-android-sample has been updated to demonstrate the new, lower-level public APIs for assembling LeakCanary. The sample now uses a new ExampleSetup class that explicitly wires up components like ActivityWatcher, FragmentAndViewModelWatcher, and ServiceWatcher using the new reachability and retention tracking interfaces. This change reflects a shift in how the library is configured, moving away from the previous high-level setup to a more modular, block-based approach.

leakcanary-android-sample · high confidence

Service communication refactored to use AIDL for heap analysis transfer

The app service now communicates with the UI app using an AIDL interface (LeakUiApp) to send heap analysis and dump URIs, replacing previous mechanisms. This change introduces a new AIDL module defining the contract and updates the service's AndroidManifest to include a \<queries\> tag for the LeakCanary package, ensuring compatibility with Android 11+ package visibility restrictions when binding to the service.

leakcanary/leakcanary-app-service · high confidence

Support for canceling heap dump analysis and reading large files concurrently

Shark now allows analysis of heap dumps to be canceled from another thread via a cooperative CancelSignal, preventing the need to interrupt threads (which would break file channel reads). This cancellation is integrated into the source providers so that work stops shortly after the signal is raised. Additionally, the file reading layer has been refactored to support concurrent random-access reads using positional reads and a capped pool of scratch arrays, enabling multiple threads to read from the same heap dump file simultaneously without race conditions or excessive memory allocation.

shark/shark-hprof/src/main · high confidence

Updated public API dump for the heap graph library

The public API surface for the heap graph module has been updated to reflect the current implementation. This includes the definition of the \CloseableHeapGraph\ interface, the \GraphContext\ class with its new \compute()\ method and null-key semantics, and the core \HeapGraph\ interface exposing methods for finding objects, classes, and threads. The API also exposes detailed object inspection capabilities through \HeapObject\ and its subtypes (\HeapClass\, \HeapInstance\, \HeapObjectArray\, \HeapPrimitiveArray\), as well as stack trace information via \HeapStackFrame\ and \HeapThread\. This dump serves as the contract for users interacting with the heap analysis features.

shark/shark-graph/api · high confidence

Test coverage

Added API surface and test infrastructure for JVM heap dump testing; Added UI test infrastructure and leak-detection test case; Added instrumentation tests for LeakCanary Android core; Added instrumentation tests for heap growth detection and out-of-memory guidance; Added instrumentation tests for leak detection and lifecycle handling; Added tests for Android test heap limit validation; Added tests for Android-specific leak analysis behaviors; Added tests for JVM live object growth detection; Added tests for LeakCanary configuration validation and out-of-memory guidance logic; Added tests for ReferenceQueueRetainedObjectTracker; Added tests for heap dump reading, cancellation, and large array handling; Added tests for the LeakCanary deobfuscation Gradle plugin; Added tests to ensure Android Studio Profiler integration stability; Expanded test coverage for heap analysis and reference reading; Expanded test coverage for heap graph parsing, concurrency, and cancellation.

Dependencies

Inlined HPPC hash structures for heap analysis

The heap graph module now includes internal, Kotlin-port implementations of HPPC's \LongObjectScatterMap\ and \LongScatterSet\ (along with supporting hash utilities), replacing the external Carrot Search HPPC dependency. This change inlines the core data structures used for tracking heap objects and references, allowing Shark to manage memory layout and traversal logic directly without external library constraints.

shark/shark-graph/src/main/java/shark/internal/hppc · high confidence

LeakCanary 3.0-alpha-10: Gradle build system modernization and dependency updates

The project has been upgraded to Kotlin 2.4.10 and Android Gradle Plugin 9.2.1, with the build infrastructure fully migrated to Kotlin DSL (build.gradle.kts) and a centralized version catalog (libs.versions.toml). This update introduces the KSP compiler plugin to replace deprecated KAPT, adopts the Dokka Gradle plugin v2 for documentation generation, and sets the minimum supported Android SDK to API 24. Additionally, the build now includes a custom Gradle plugin for GFM documentation generation and configures the AndroidX Startup library for optional auto-installation of the Object Watcher and Plumber components.

(dependencies) · high confidence

Updated Gradle wrapper to version 9.6.1

The Gradle wrapper configuration has been updated to use Gradle version 9.6.1. This change ensures that builds are executed using the specified distribution, with network timeout and retry settings configured for reliability.

gradle · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 54 → 65 (+11.4)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 81 → 88 (+6.8)
  • Architecture 99 → 88 (-11.3)
  • Maturity 40 → 57 (+16.6)
  • Readiness 60 → 60 (+0.0)
  • Security 58 → 81 (+22.9)

Resolved (54)

  • Change coupling: ActivityWatcher.kt ↔ AndroidOFragmentDestroyWatcher.kt (object-watcher/object-watcher-android-core/src/main/java/leakcanary/ActivityWatcher.kt)
  • Change coupling: AndroidXFragmentDestroyWatcher.kt ↔ AndroidOFragmentDestroyWatcher.kt (object-watcher/object-watcher-android-androidx/src/main/java/leakcanary/internal/AndroidXFragmentDestroyWatcher.kt)
  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • DominatorTree.updateDominated (cognitive 22) (shark/shark/src/main/java/shark/DominatorTree.kt)
  • Duplicated block (10 lines × 2) (shark/shark-cli/src/main/java/shark/Neo4JCommand.kt)
  • Duplicated block (11 lines × 2) (shark/shark-cli/src/main/java/shark/Neo4JCommand.kt)
  • Duplicated block (11 lines × 2) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • Duplicated block (13 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/HeapDumpTrigger.kt)
  • Duplicated block (13 lines × 2) (shark/shark-graph/src/main/java/shark/internal/ClassFieldsReader.kt)
  • Duplicated block (13 lines × 2) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • Duplicated block (13 lines × 2) (shark/shark/src/main/java/shark/ApacheHarmonyInstanceRefReaders.kt)
  • Duplicated block (13 lines × 2) (shark/shark/src/main/java/shark/OpenJdkInstanceRefReaders.kt)
  • Duplicated block (13 lines × 3) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • Duplicated block (14 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/AndroidDebugHeapAnalyzer.kt)
  • Duplicated block (14 lines × 2) (shark/shark-hprof-test/src/main/kotlin/shark/HprofWriterHelper.kt)
  • Duplicated block (15 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/AndroidDebugHeapAnalyzer.kt)
  • Duplicated block (15 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/activity/screen/LeakTraceWrapper.kt)
  • Duplicated block (15 lines × 2) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • Duplicated block (16 lines × 2) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • …and 34 more

New (161)

  • AgentSessionFileKt.verbOfTool (cyclomatic 23) (shark/shark-dive/shark-dive-agent/src/main/java/shark/dive/agent/AgentSessionFile.kt)
  • AgentStdioBridgeKt.waitForRun (cognitive 20) (shark/shark-dive/shark-dive-agent/src/main/java/shark/dive/agent/AgentStdioBridge.kt)
  • CellColors.of (cognitive 22) (shark/shark-dive/shark-dive-app/src/main/java/shark/dive/app/CellColors.kt)
  • Change coupling: HeapAnalyzer.kt ↔ ObjectDominators.kt (shark/shark/src/main/java/shark/HeapAnalyzer.kt)
  • Change coupling: Main.kt ↔ TreemapView.kt (shark/shark-dive/shark-dive-app/src/main/java/shark/dive/app/Main.kt)
  • Change-coupling hub: HeapDumpDive.kt → LeaksScreen.kt, Main.kt, TreemapView.kt (shark/shark-dive/shark-dive-app/src/main/java/shark/dive/app/HeapDumpDive.kt)
  • ClassTooLong: AgentTools (shark/shark-dive/shark-dive-agent/src/main/java/shark/dive/agent/AgentTools.kt)
  • ClassTooLong: HeapDominatorTreemap (shark/shark-dive/shark-dive-core/src/main/java/shark/dive/HeapDominatorTreemap.kt)
  • ClassTooLong: HprofInMemoryIndex (shark/shark-graph/src/main/java/shark/internal/HprofInMemoryIndex.kt)
  • ClassTooLong: Neo4JCommand (shark/shark-cli/src/main/java/shark/Neo4JCommand.kt)
  • Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
  • Documentation: no architecture or design documentation (docs/dev-env.md)
  • Duplicated block (10 lines × 2) (shark/shark-dive/shark-dive-agent/src/main/java/shark/dive/agent/AgentServer.kt)
  • Duplicated block (10 lines × 2) (shark/shark-dive/shark-dive-agent/src/main/java/shark/dive/agent/AgentServer.kt)
  • Duplicated block (10 lines × 2) (shark/shark-graph/src/main/java/shark/internal/hppc/LongLongScatterMap.kt)
  • Duplicated block (10 lines × 3) (shark/shark-graph/src/main/java/shark/internal/ClassFieldsReader.kt)
  • Duplicated block (100 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/activity/screen/LeakTraceWrapper.kt)
  • Duplicated block (11 lines × 2) (shark/shark-cli/src/main/java/shark/Neo4JCommand.kt)
  • Duplicated block (13 lines × 2) (shark/shark-graph/src/main/java/shark/internal/ClassFieldsReader.kt)
  • Duplicated block (13–14 lines × 2) (leakcanary/leakcanary-android-core/src/main/java/leakcanary/internal/HeapDumpTrigger.kt)
  • …and 141 more

Changes since last survey

  • 122 commits — 120 feature/other, 2 fixes

By area

  • shark/shark-explorer — 68 commits
  • (repo) — 26 commits
  • shark/shark-dive — 13 commits
  • (root) — 4 commits
  • docs/changelog.md — 3 commits
  • shark/shark-hprof — 3 commits
  • shark/shark-graph — 2 commits
  • docs/shark-dive-changelog.md — 1 commit
  • leakcanary/leakcanary-android-core — 1 commit
  • shark/shark — 1 commit

Notable commits

  • fix: Merge pull request #2940 from square/fix-the-agents-md-claim-that-d
  • fix: Merge pull request #2942 from square/fix-wait-for-green-guidance
  • change: Answer "Should it be here?" in the panel, and in the leaks
  • change: Answer an agent with the link to what it showed
  • change: Answer an agent with what has already been tried on this heap dump
  • change: Call a tool from a shell, at the window that is already open
  • change: Copy a shark:// link to a tab, and follow one back to it
  • change: Delete the paragraphs saying what the picture already said
  • change: Delta encode the referrer index instead of a linked list per object
  • change: Document Shark Explorer on the LeakCanary site
  • change: Drag the note's bottom edge to make it taller
  • change: Draw the activities an app is running under the thread running them
  • change: Draw the whole chain from a GC root, however long it is
  • change: Find the leaks as the heap dump opens
  • change: Fold a leak that can only be reached through another leak
  • change: Fold the sections nobody has to act on under one heading
  • change: Give each reachability strength one name
  • change: Give each way out of memory its own section on the leaks screen
  • change: Hand out a map's entries, node included, for what a leak trace leaves out
  • change: Hang the note button under the title, small
  • …and 102 more

Architecture

  • Containers 0 added · 0 removed · contexts 19 added · 1 removed · edges 30 added · 0 removed

Added bounded contexts (19)

  • leakcanary-android-core
  • leakcanary-android-instrumentation
  • leakcanary-android-release
  • leakcanary-android-sample
  • leakcanary-app
  • leakcanary-app-aidl
  • leakcanary-test-core
  • object-watcher
  • plumber-android-core
  • shark-android
  • shark-cli
  • shark-dive-agent
  • shark-dive-app
  • shark-dive-core
  • shark-dive-eval
  • shark-dive-jdwp
  • shark-graph
  • shark-hprof
  • shark-hprof-test

Removed bounded contexts (1)

  • .

Added dependency edges (30)

  • leakcanary-android-core → object-watcher
  • leakcanary-android-core → shark (coupling)
  • leakcanary-android-core → shark-graph
  • leakcanary-android-core → shark-hprof
  • leakcanary-android-instrumentation → object-watcher
  • leakcanary-android-instrumentation → shark (coupling)
  • leakcanary-android-instrumentation → shark-hprof
  • leakcanary-android-release → shark
  • leakcanary-android-release → shark-graph
  • leakcanary-android-release → shark-hprof
  • leakcanary-android-sample → object-watcher
  • leakcanary-app → shark (coupling)
  • leakcanary-app-aidl → shark
  • shark → shark-graph
  • shark → shark-hprof (coupling)
  • shark-android → shark (coupling)
  • shark-android → shark-graph
  • shark-cli → shark-graph
  • shark-dive-agent → shark-dive-core (coupling)
  • shark-dive-app → shark-dive-agent
  • …and 10 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

square/leakcanary was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 66aab8d2ab695c4e1c013ed1bd5c3884939c1e2f — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-821afab8930d.