Issue 31675: Tkinter: memory leak in splitlines() and split() (original) (raw)

This issue has been migrated to GitHub: https://github.com/python/cpython/issues/75856

classification

Title: Tkinter: memory leak in splitlines() and split()
Type: resource usage Stage: resolved
Components: Tkinter Versions: Python 3.7, Python 3.6, Python 2.7

process

Status: closed Resolution: fixed
Dependencies: 31673 Superseder:
Assigned To: serhiy.storchaka Nosy List: serhiy.storchaka, vstinner
Priority: normal Keywords: patch

Created on 2017-10-03 12:04 by serhiy.storchaka, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 3866 merged serhiy.storchaka,2017-10-03 12:25
PR 3874 merged python-dev,2017-10-03 19:40
PR 3876 merged serhiy.storchaka,2017-10-03 21:41
Messages (7)
msg303599 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-03 12:04
There is a memory leak in Tkinter's methods splitlines() and split() when pass a string larger than 2 GiB (when encoded to UTF-8).
msg303602 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2017-10-03 12:18
Which function? Do you mean split() and splitlist() methods of tkapp? C functions _tkinter_tkapp_split() and _tkinter_tkapp_splitlist(). Do you know how to reproduce the memory leak?
msg303604 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-03 12:35
Just run the bigmem tests with ulimit (after fixing ). (ulimit -v 4350000; ./python -m test -vuall -M4G test_tcl)
msg303611 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2017-10-03 12:55
Oh, Python splitlist() doesn't seem to be documented. Tcl SplitList documentation: https://www.tcl.tk/man/tcl/TclLib/SplitList.htm
msg303643 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-03 19:39
New changeset 27c623c845dd6e4b8e1782666ca3a956636da266 by Serhiy Storchaka in branch 'master': bpo-31675: Fix memory leaks in Tkinter's methods splitlist() and split() (#3866) https://github.com/python/cpython/commit/27c623c845dd6e4b8e1782666ca3a956636da266
msg303648 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-03 20:50
New changeset a65b2420f681c45db43e94bfe3dc50ad1dfcd03d by Serhiy Storchaka (Miss Islington (bot)) in branch '3.6': [3.6] bpo-31675: Fix memory leaks in Tkinter's methods splitlist() and split() (GH-3866) (#3874) https://github.com/python/cpython/commit/a65b2420f681c45db43e94bfe3dc50ad1dfcd03d
msg303726 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-10-04 18:37
New changeset 328b5d0e64798cf17360c6b2a07c2b18f2798b88 by Serhiy Storchaka in branch '2.7': [2.7] bpo-31675: Fix memory leaks in Tkinter's methods splitlist() and split() (GH-3866) (#3876) https://github.com/python/cpython/commit/328b5d0e64798cf17360c6b2a07c2b18f2798b88
History
Date User Action Args
2022-04-11 14:58:53 admin set github: 75856
2017-10-04 19:02:26 serhiy.storchaka set status: open -> closedresolution: fixedstage: patch review -> resolved
2017-10-04 18:37:55 serhiy.storchaka set messages: +
2017-10-03 21:41:15 serhiy.storchaka set pull_requests: + <pull%5Frequest3855>
2017-10-03 20:50:48 serhiy.storchaka set messages: +
2017-10-03 19:40:09 python-dev set pull_requests: + <pull%5Frequest3853>
2017-10-03 19:39:58 serhiy.storchaka set messages: +
2017-10-03 12:55:38 vstinner set messages: +
2017-10-03 12:35:15 serhiy.storchaka set messages: +
2017-10-03 12:25:13 serhiy.storchaka set keywords: + patchpull_requests: + <pull%5Frequest3846>
2017-10-03 12🔞06 vstinner set nosy: + vstinnermessages: +
2017-10-03 12:09:17 serhiy.storchaka set dependencies: + Fix the name of Tkinter's adderrorinfo method
2017-10-03 12:04:33 serhiy.storchaka set assignee: serhiy.storchaka
2017-10-03 12:04:23 serhiy.storchaka create