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

TST: Remove memory leak test by QuLogic · Pull Request #27732 · matplotlib/matplotlib · GitHub

Repository navigation

TST: Remove memory leak test - #27732

Merged
ksunden merged 1 commit into
matplotlib:mainfrom
QuLogic:no-leak-test
Feb 5, 2024
Merged

ksunden merged 1 commit into
matplotlib:mainfrom
QuLogic:no-leak-test

Conversation

QuLogic commented Feb 1, 2024

Copy link
Copy Markdown
Member

PR summary

It is flaky, and our memory "limit" is pretty much arbitrary. Testing with tools/memleak.py shows that memory usage generally rises and only stabilizes close to 200 figures, while this test only does a warmup of 2 figures. Waiting for equilibrium would take too long for a general test, so we might move this to a weekly job later.

For example, with just Agg:

and with the flaky wxAgg:

It's true that the latter uses more memory, but it still takes about 200 or so figure to reach equilibrium.

Closes #27635

PR checklist

It is flaky, and our memory "limit" is pretty much arbitrary. Testing
with `tools/memleak.py` shows that memory usage generally rises and only
stabilizes close to 200 figures, while this test only does a warmup of
2 figures. Waiting for equilibrium would take too long for a general
test, so we might move this to a weekly job later.
QuLogic added this to the v3.9.0 milestone Feb 1, 2024

Copy link
Copy Markdown
Contributor

I'd be on board with a weekly run that's not tied to PRs. After all we're not really worried about any specific threshold, just if things are growing excessively, and a weekly trend would be easy to bisect, at least compared to bug reports.

Maybe it would be worth putting together a whole pythonspeed thing with benchmarks and memory usage?

dstansby commented Feb 4, 2024

Copy link
Copy Markdown
Member

I presume the x-axis in those plots is elapsed time in seconds? I'm 👍 to removing these to stop the CI failing for now given it doesn't seem like there's an easy or quick fix to the tests, but would be worth opening an issue to discuss ways to fix these tests or add replacement memory leak tests.

Copy link
Copy Markdown
Member

I presume the x-axis in those plots is elapsed time in seconds?

The x-axis is cycle count (so how many Figures we have created and destroyed).

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: test_figure_leak_20490 repeatedly failing on CI

5 participants


Back | FazBrowse Home | New Git URL