Skip to content

Enable leak tracking for Codec #161132

@polina-c

Description

@polina-c

Motivation: #159945 (comment)

  • add properties onCreate and onDispose to Codec
    • BitmapSingleFrameCodec
    • ResizingCodec
    • BrowserImageDecoder
    • HtmlImageElementCodec
    • CkAnimatedImage
  • update MemoryAllocations to monitor codec with flag deprecatedDoNotUseWillBeRemovedWithoutNoticeLeakTrackCodec, that is false by defailt
  • update flutter_test_config to set deprecatedDoNotUseWillBeRemovedWithoutNoticeLeakTrackCodec to true
    and opt out all failing tests from leak tracking
  • clean up leaks in FF
  • remove flag deprecatedDoNotUseWillBeRemovedWithoutNoticeLeakTrackCodec

flag code:

/// If true, Codec is leak tracked.
///
/// For use in Flutter tests only.
/// Do not take dependency. It will be deleted without notice.
// TODO (https://github.com/flutter/flutter/issues/161132): remove after fixing the tests.
bool deprecatedDoNotUseWillBeRemovedWithoutNoticeLeakTrackCodec = false;

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: leak trackingIssues and PRs related to memory leaks detected by leak_trackerengineflutter/engine related. See also e: labels.team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions