This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Reference leak in PyErr_WarnEx()
Type: resource usage Stage: resolved
Components: Interpreter Core Versions: Python 3.9, Python 3.8, Python 3.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: miss-islington, ned.deily, pablogsal, serhiy.storchaka
Priority: normal Keywords: patch

Created on 2020-03-02 19:40 by serhiy.storchaka, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 18750 merged serhiy.storchaka, 2020-03-02 19:43
PR 18760 merged pablogsal, 2020-03-03 00:49
PR 18761 merged pablogsal, 2020-03-03 00:52
PR 18764 merged serhiy.storchaka, 2020-03-03 08:51
PR 18765 merged serhiy.storchaka, 2020-03-03 08:52
PR 18770 merged miss-islington, 2020-03-03 17:43
Messages (12)
msg363203 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2020-03-02 19:40
The test added for issue38913 exposed a reference leak in PyErr_WarnEx().
msg363207 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2020-03-02 20:05
New changeset 2d2f85517f8216146a2f888d1ad4d765b3be2339 by Serhiy Storchaka in branch 'master':
bpo-39831: Fix a reference leak in PyErr_WarnEx(). (GH-18750)
https://github.com/python/cpython/commit/2d2f85517f8216146a2f888d1ad4d765b3be2339
msg363228 - (view) Author: Pablo Galindo Salgado (pablogsal) * (Python committer) Date: 2020-03-03 00:53
I made the backports to 3.7 and 3.8 manually to calm down the refleak buildbots as the automatic backports failed :)
msg363229 - (view) Author: Pablo Galindo Salgado (pablogsal) * (Python committer) Date: 2020-03-03 01:13
New changeset 394dc0db878c08d003772de163a57ac12046d865 by Pablo Galindo in branch '3.8':
[3.8] bpo-39831: Fix a reference leak in PyErr_WarnEx(). (GH-18750) (GH-18761)
https://github.com/python/cpython/commit/394dc0db878c08d003772de163a57ac12046d865
msg363230 - (view) Author: Pablo Galindo Salgado (pablogsal) * (Python committer) Date: 2020-03-03 01:13
New changeset 499c926fbeafa7e4c15d925fea27fe8a65cc3b25 by Pablo Galindo in branch '3.7':
[3.7] bpo-39831: Fix a reference leak in PyErr_WarnEx(). (GH-18750). (GH-18760)
https://github.com/python/cpython/commit/499c926fbeafa7e4c15d925fea27fe8a65cc3b25
msg363231 - (view) Author: Pablo Galindo Salgado (pablogsal) * (Python committer) Date: 2020-03-03 01:16
Closing this as the backports are merged.

Thanks, Serhiy, for finding the leak and for the fix :)
msg363242 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2020-03-03 08:44
It is not so easy for 3.7.
msg363281 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2020-03-03 17:43
New changeset ae75a294352e9b9487f5dc8e88f068e7e6974dc2 by Serhiy Storchaka in branch 'master':
bpo-39831: Remove outdated comment. (GH-18764)
https://github.com/python/cpython/commit/ae75a294352e9b9487f5dc8e88f068e7e6974dc2
msg363282 - (view) Author: miss-islington (miss-islington) Date: 2020-03-03 18:01
New changeset 57fb29219f09ee705065e39ad488334a9c7e3d71 by Miss Islington (bot) in branch '3.8':
bpo-39831: Remove outdated comment. (GH-18764)
https://github.com/python/cpython/commit/57fb29219f09ee705065e39ad488334a9c7e3d71
msg363283 - (view) Author: Pablo Galindo Salgado (pablogsal) * (Python committer) Date: 2020-03-03 18:04
> It is not so easy for 3.7.

Apologies Serhiy, I thought it was more straightforward and just wanted to stop the mail storm that the refleak buildbots were causing :(
msg363314 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2020-03-03 22:32
Is the 3.7.x backport (PR 18765) ready to merge?
msg363666 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2020-03-08 16:08
New changeset 89fabe51af27a16ae71733334ad94921e3980e28 by Serhiy Storchaka in branch '3.7':
[3.7] bpo-39831: Fix a reference leak in PyErr_WarnEx(). (GH-18750). (GH-18765)
https://github.com/python/cpython/commit/89fabe51af27a16ae71733334ad94921e3980e28
History
Date User Action Args
2022-04-11 14:59:27adminsetgithub: 84012
2020-03-08 16:09:01serhiy.storchakasetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2020-03-08 16:08:12serhiy.storchakasetmessages: + msg363666
2020-03-03 22:32:50ned.deilysetnosy: + ned.deily
messages: + msg363314
2020-03-03 18:04:21pablogsalsetmessages: + msg363283
2020-03-03 18:01:16miss-islingtonsetmessages: + msg363282
2020-03-03 17:43:57miss-islingtonsetnosy: + miss-islington
pull_requests: + pull_request18129
2020-03-03 17:43:36serhiy.storchakasetmessages: + msg363281
2020-03-03 08:52:41serhiy.storchakasetpull_requests: + pull_request18120
2020-03-03 08:51:29serhiy.storchakasetstage: patch review
pull_requests: + pull_request18119
2020-03-03 08:44:35serhiy.storchakasetstatus: closed -> open
resolution: fixed -> (no value)
messages: + msg363242

stage: resolved -> (no value)
2020-03-03 01:16:14pablogsalsetstatus: open -> closed
resolution: fixed
messages: + msg363231

stage: patch review -> resolved
2020-03-03 01:13:27pablogsalsetmessages: + msg363230
2020-03-03 01:13:16pablogsalsetmessages: + msg363229
2020-03-03 00:53:37pablogsalsetmessages: + msg363228
2020-03-03 00:52:11pablogsalsetpull_requests: + pull_request18116
2020-03-03 00:49:05pablogsalsetnosy: + pablogsal
pull_requests: + pull_request18115
2020-03-02 20:05:12serhiy.storchakasetmessages: + msg363207
2020-03-02 19:43:07serhiy.storchakasetkeywords: + patch
stage: patch review
pull_requests: + pull_request18105
2020-03-02 19:40:18serhiy.storchakacreate