Skip to content
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

Fix resource leak by closing opened file handles #121

Merged

Conversation

northernSage
Copy link
Member

Fix #119

We now just use the already created reference to the opened file stream instead of opening another one. Since, the stream is closed on XProcessResouce.__del__, ResourceWarnings should no longer show.

@northernSage northernSage self-assigned this Dec 31, 2022
@northernSage northernSage merged commit 167f269 into pytest-dev:master Dec 31, 2022
@northernSage northernSage deleted the fix-resource-warnings-119 branch December 31, 2022 16:51
@northernSage northernSage mentioned this pull request Jan 5, 2023
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.

ResourceWarning in xprocess.ensure
1 participant