Created on 2018-12-05 08:54 by Tiger-222, last changed 2019-04-08 13:20 by methane. This issue is now closed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 10918 | merged | Tiger-222, 2018-12-05 08:59 | |
| Messages (6) | |||
|---|---|---|---|
| msg331097 - (view) | Author: Mickaël Schoentgen (Tiger-222) * | Date: 2018-12-05 08:54 | |
I am looking to clean-up potential ResourceWarnings in distutils. The patch will provide 2 changes:
- ensure file descriptor are always closed when it is not the case
- and uniformization of the "with open(...)" use
|
|||
| msg331107 - (view) | Author: Karthikeyan Singaravelan (xtreak) * | Date: 2018-12-05 12:55 | |
There is a similar open issue issue22831 with patches for distutils and Tools. |
|||
| msg331110 - (view) | Author: Mickaël Schoentgen (Tiger-222) * | Date: 2018-12-05 13:10 | |
I saw it but it is quite old and targetting 3.5. I opended this issue to target only distutils, easier to eventually backport than a big patch on a lot of files. |
|||
| msg331114 - (view) | Author: Éric Araujo (eric.araujo) * | Date: 2018-12-05 14:08 | |
I think the places that already use try/finally: close are correct. We try to minimize churn in distutils; changing to with is nice but does not fix errors or warning in these cases. The changes for the few spots that don’t use finally: close are welcome though! |
|||
| msg331118 - (view) | Author: Mickaël Schoentgen (Tiger-222) * | Date: 2018-12-05 14:38 | |
OK then I updated the PR to only update code that would really leak resources. |
|||
| msg339635 - (view) | Author: Inada Naoki (methane) * | Date: 2019-04-08 13:08 | |
New changeset 58721a903074d28151d008d8990c98fc31d1e798 by Inada Naoki (Mickaël Schoentgen) in branch 'master': bpo-35416: fix potential resource warnings in distutils (GH-10918) https://github.com/python/cpython/commit/58721a903074d28151d008d8990c98fc31d1e798 |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2019-04-08 13:20:52 | methane | set | status: open -> closed resolution: fixed stage: patch review -> resolved |
| 2019-04-08 13:08:54 | methane | set | nosy:
+ methane messages: + msg339635 |
| 2018-12-05 14:38:17 | Tiger-222 | set | messages: + msg331118 |
| 2018-12-05 14:08:14 | eric.araujo | set | messages: + msg331114 |
| 2018-12-05 13:10:06 | Tiger-222 | set | messages: + msg331110 |
| 2018-12-05 12:55:57 | xtreak | set | nosy:
+ serhiy.storchaka, xtreak messages: + msg331107 |
| 2018-12-05 08:59:35 | Tiger-222 | set | keywords:
+ patch stage: patch review pull_requests: + pull_request10157 |
| 2018-12-05 08:54:19 | Tiger-222 | create | |