Viewing version 11.0.2. Open the latest package page.

leak_tracker

11.0.2

A framework for memory leak tracking for Dart and Flutter applications.

Download archive

Readme

pub package package publisher

What is this?

This is a framework for detecting memory issues in Dart and Flutter applications.

Read more in leak tracking overview.

Changelog

11.0.2

  • Update README.md.

11.0.1

  • Add method tracked to LeakTracking.

11.0.0

  • Remove integration with DevTools and class LeakTrackingTestConfig.
  • Update vm_service dependency to >=11.0.0 <16.0.0.

10.0.8

  • Make link to documentation customizable.

10.0.7

  • Fix broken link in error message.

10.0.6

  • Handle double tracking.

10.0.5

  • Stop failing if finalization happened twice.

10.0.4

  • Add exceptions to test helpers.

10.0.3

  • Improve performance of the case with ignored test helpers.

10.0.2

  • Require Dart SDK 3.2.0 or later.

10.0.1

  • Allow to ignore objects created by test helpers.

10.0.0

9.0.18

  • Update vm_service dependency to >=11.0.0 <15.0.0.

9.0.17

  • Move LeakTesting to leak_tracker_testing.

9.0.16

  • Stub web implementation for retaining path to serve G3.

9.0.15

  • Fix: debug information should not wipe other settings.
  • Add arguments allNotGCed and allNotDisposed to withTracked.
  • Remove the dependency on package:intl.
  • Updated to use package:lints/recommended.yaml for analysis.

9.0.14

  • Remove the dependency on package:web_socket_channel.

9.0.13

  • Define LeakTesting.

9.0.12

  • Update vm_service dependency to >=11.0.0 <14.0.0.

9.0.11

  • Remove dependency on logging.
  • Avoid double leak tracking.

9.0.10

  • Use IgnoredLeaks.

9.0.9

  • Define IgnoredLeaks.
  • Add item none to BaseliningMode.

9.0.8

  • Enable declaring all not disposed objects as leaks.

9.0.7

  • Use ObjectRecord instead of hash code to identify objects.
  • Remove collection of stack trace by class in LeakDiagnosticConfig.
  • Bump version of SDK to 3.1.2.

9.0.6

  • Improve error reporting for connection to vm service.
  • Fix misspelling.
  • Enable memory baselining.

9.0.5

  • Fix issue of using wrong settings for a phase, so that the tracker uses settings at time of object tracking start, instead of current configuration.

9.0.4

  • Make it possible to disable tracking for a type of leak.

9.0.3

  • Stop failing if an object is disposed twice.

9.0.2

  • Make sure phase boundaries are handled correctly.

9.0.1

  • Auto-start VM Service when needed.

9.0.0

  • Refactor to improve performance of regression tests with leak tracking.
  • Remove API that is not used in Flutter Framework.
  • Rename LeakTrackingConfiguration to LeakTrackingConfig.
  • Remove global flag [collectDebugInformationForLeaks].
  • Rename checkNonGCed to checkNotGCed and collectRetainingPathForNonGCed to collectRetainingPathForNotGCed.
  • Group global items related to leak tracking, in abstract class LeakTracking.
  • Rename gcCountBuffer to numberOfGcCycles and disposalTimeBuffer to disposalTime.

8.0.3

  • Fix an issue with custom gcCountBuffer values.

8.0.2

  • Improve performance.
  • Make gcCountBuffer customizable with default value 3.

8.0.1

  • Handle SentinelException for retaining path.
  • Limit number of requests for retaining path.

8.0.0

  • Enable turn on/off tracking for leak types.
  • Put all global flags into one class.

7.0.8

  • Disconnect from service after obtaining retaining paths.
  • Protect from identityHashCode equal to 0.

7.0.6

  • Add helpers for troubleshooting.
  • Handle generic arguments for retaining path detection.
  • Convert to multi-package.

7.0.4

  • Fix path collection.
  • Create constructor to collect path.
  • Fix connection issue.
  • Improve retaining path formatting.
  • Format retaining path nicely.
  • Enable collection of retaining path.
  • Separate testing.
  • Fixes to support g3.
  • Fix for MemoryUsageEvent constructor.

6.0.0

  • Fix typo in public API.
  • Add assertion for negative delay between snapshots.

5.0.0

  • Migrate from auto-snapshotting to usage-tracking.
  • Improve leak debugging UX.
  • Fix failures in case of duplicates.

4.0.3

  • Fix broken documentation link.

4.0.2

  • Improve documentation.

4.0.1

  • Autosnapshotting.

4.0.0

  • Improve documentation and naming.

3.0.2

  • Add members to LeakTrackingTestConfig.

3.0.1

  • Increase sdk version
  • Remove obsolete lint

3.0.0

  • Breaking changes: update names of types to be align with Flutter naming convention.
  • Add model for Flutter unit testing configuration.
  • Adopt Flutter standard lints.
  • Improve documentation.

2.0.1

  • Minor changes.
  • Updated vm_service version to >=9.0.0 <12.0.0.

2.0.0

  • Breaking changes in withLeakTracking.
  • Refactor test_infra libraries.
  • Documentation updates.

1.0.0

  • First release.

Installing

export PUB_HOSTED_URL=https://pub.mirror.p-hatan.com
flutter pub add 'leak_tracker:11.0.2'
pubspec.yaml
name: leak_tracker
version: 11.0.2
description: A framework for memory leak tracking for Dart and Flutter applications.
repository: https://github.com/dart-lang/leak_tracker/tree/main/pkgs/leak_tracker

environment:
  sdk: ^3.2.0

# All dependencies here will become Flutter transitive dependencies.
# Follow the process when adding:
# https://github.com/flutter/flutter/blob/2be9b613099250cf8e84e1498a7624d9d2e04023/dev/bots/allowlist.dart#L13
dependencies:
  clock: ^1.1.1
  collection: ^1.15.0
  meta: ^1.8.0
  path: ^1.8.3
  vm_service: '>=11.10.0 <16.0.0'

dev_dependencies:
  dart_flutter_team_lints: ^3.1.0
  layerlens: ^1.0.16
  test: ^1.16.0

Version history

VersionPublishedArchiveSHA-256
1.0.0-dev.1.0On demandDownload4bc8e1b8…f47ea7
1.0.0-dev.1.1On demandDownload6384aa1f…3c3b4f
1.0.0-dev.1.2On demandDownload4ac3c099…4fbc7e
1.0.0-dev.1.4On demandDownload83ffb454…915727
1.0.0-dev.1.5On demandDownload9e31a49a…5b1f54
1.0.0-dev.1.6On demandDownload3c99a418…b52ca4
1.0.0On demandDownload9bfddf60…a050e3
2.0.0On demandDownload4b19d950…cab89a
2.0.1On demandDownloadc320b5b7…da2ff1
2.0.2-dev.0.0On demandDownloadbd5f8753…d4ef9d
3.0.0On demandDownload311caa20…5213fa
3.0.1On demandDownload5fc1ba47…d8cd1b
3.0.2On demandDownload548391a8…8f3629
4.0.0On demandDownload647e70e8…903537
4.0.1On demandDownloadadb88e56…9c6e07
4.0.2On demandDownloadfcd17ea9…63714f
4.0.3On demandDownloadd336e115…61ac98
5.0.0On demandDownload7e0c8bf9…72e627
6.0.0On demandDownload13aa0f9a…72a6b8
7.0.4On demandDownload187cf9b3…fae271
7.0.6On demandDownload4c7af9fa…8d8397
7.0.8On demandDownloadaa08fd11…9b51fd
8.0.0On demandDownloade2a21bff…b37e67
8.0.1On demandDownload1f0da0e5…2f8c3a
8.0.2On demandDownload88a9b89f…6c34ab
8.0.3On demandDownload5ff3f443…086773
9.0.0On demandDownload99d0c8b7…6bd560
9.0.1On demandDownload0412bdcd…52c2fd
9.0.2On demandDownloadc5e44f38…f163dc
9.0.3On demandDownload0b9d33f0…9bbbc7
9.0.4On demandDownloadc9220a3b…9a8ac5
9.0.5On demandDownloadbfe38d2b…5eacf1
9.0.6On demandDownloadb63ca5cc…3f0a9a
9.0.7On demandDownload02c9fd5f…b3ecea
9.0.8On demandDownload0b23f6d9…f09244
9.0.9On demandDownload6c530a4a…c88189
9.0.10On demandDownloada8fa35d3…deadd3
9.0.11On demandDownloadf38a2c91…eee6a2
9.0.12On demandDownloade7673f20…6a85f6
9.0.13On demandDownload7e108028…21a9dc
9.0.14On demandDownload2c30f27a…c43f4d
9.0.15On demandDownloadd51aa223…094408
9.0.16On demandDownload04be76c4…2fc739
9.0.17On demandDownload41b90cea…031422
9.0.18On demandDownloade45c31f4…48c021
10.0.0On demandDownload78eb209d…a323fa
10.0.1On demandDownloadf8cdf138…932624
10.0.2On demandDownload94b0776f…8afac0
10.0.3On demandDownloadcdd14e38…bcf831
10.0.4On demandDownload7f0df319…9d341a
10.0.5On demandDownload3f87a60e…f0ce05
10.0.7On demandDownload7bb2830e…1d2d06
10.0.8On demandDownloadc35baad6…61acec
10.0.9On demandDownload6bb818ec…fb6ab0
11.0.1On demandDownload8dcda04c…2081e0
11.0.2Cached · Upstream SHA-256 matchedDownload33e2e26b…15e2de

Dependencies

clock "^1.1.1"

collection "^1.15.0"

meta "^1.8.0"

path "^1.8.3"

vm_service "\u003e=11.10.0 \u003c16.0.0"