Skip to content

Memory leak in CTracer #1924

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
nedbat opened this issue Feb 6, 2025 · 2 comments
Closed

Memory leak in CTracer #1924

nedbat opened this issue Feb 6, 2025 · 2 comments
Labels
bug Something isn't working fixed

Comments

@nedbat
Copy link
Owner

nedbat commented Feb 6, 2025

Described in more detail at pytest-dev/pytest-cov#676

The CTracer leaks code objects. This can cause the memory footprint to grow, especially if a large number of code objects are created, as with eval() in a loop as described in the pytest-dev report.

@nedbat nedbat added the bug Something isn't working label Feb 6, 2025
nedbat added a commit that referenced this issue Feb 6, 2025
nedbat added a commit that referenced this issue Feb 6, 2025
@nedbat
Copy link
Owner Author

nedbat commented Feb 6, 2025

This is fixed in commit f85d9b7.

@nedbat nedbat closed this as completed Feb 6, 2025
@nedbat nedbat added the fixed label Feb 6, 2025
nedbat added a commit that referenced this issue Feb 8, 2025
This is a subtler check for leaks, and still clearly distinguishes
between the broken code and the fixed code.
@nedbat
Copy link
Owner Author

nedbat commented Feb 8, 2025

This is now released as part of coverage 7.6.11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed
Projects
None yet
Development

No branches or pull requests

1 participant