FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix FigureCanvasTkAgg memory leak via weakrefs by richardsheridan · Pull Request #25097 · matplotlib/matplotlib · GitHub

Repository navigation

fix FigureCanvasTkAgg memory leak via weakrefs - #25097

Merged
ksunden merged 1 commit into
matplotlib:mainfrom
richardsheridan:24820-figurecanvastkagg-memory-leak
Feb 7, 2023
Merged

ksunden merged 1 commit into
matplotlib:mainfrom
richardsheridan:24820-figurecanvastkagg-memory-leak

Conversation

Copy link
Copy Markdown
Contributor

PR Summary

Fixes #24820

May be worth checking if the memory leak tests can be tightened.

PR Checklist

Documentation and Tests

  • Has pytest style unit tests (and pytest passes)
  • Documentation is sphinx and numpydoc compliant (the docs should build without error).
  • New plotting related features are documented with examples.

Release Notes

  • New features are marked with a .. versionadded:: directive in the docstring and documented in doc/users/next_whats_new/
  • API changes are marked with a .. versionchanged:: directive in the docstring and documented in doc/api/next_api_changes/
  • Release notes conform with instructions in next_whats_new/README.rst or next_api_changes/README.rst

tacaswell added this to the v3.7.0 milestone Jan 27, 2023

Copy link
Copy Markdown
Member

I think it is worth the risk to backport memory-leak fixes.

Copy link
Copy Markdown
Member

The flake8 is understood and fixed else where already.

Copy link
Copy Markdown
Contributor Author

This could lead to user breakage since things that were once immortal are now possibly short lived, just like in the original issue.

Copy link
Copy Markdown
Contributor Author

Maybe that was a hasty comment. They should live until someone calls destroy on canvas.get_tk_widget() or its parent, which should be reasonably predictable.

ksunden commented Feb 3, 2023

Copy link
Copy Markdown
Member

Okay, having convinced myself that these changes work I think it seems fine.

@richardsheridan are you still thinking that things may be too short lived, or was that last comment pretty convinced it is okay?

Copy link
Copy Markdown
Contributor Author

I'm satisfied that those binds won't be released too early from any practical user perspective.

ksunden merged commit 472ebaa into matplotlib:main Feb 7, 2023
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Feb 7, 2023
richardsheridan deleted the 24820-figurecanvastkagg-memory-leak branch February 7, 2023 17:40
ksunden mentioned this pull request Feb 20, 2023
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FigureCanvasTkAgg memory leak

4 participants


Back | FazBrowse Home | New Git URL