homepage

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.

Author vstinner
Recipients fengjiang, martin.panter, vstinner
Date 2021年09月24日.15:51:58
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1632498718.77.0.189923182595.issue43050@roundup.psfhosted.org>
In-reply-to
Content
I cannot reproduce the issue. IMO it has been fixed.
Moreover, you must join timers using timer.join(): a timer remains a thread.
Code:
---
import os
import threading
os.system(f"grep ^VmRSS /proc/{os.getpid()}/status")
# warmup
for n in range(10):
 timer = threading.Timer(5, None)
 timer.start()
 timer.cancel()
 timer.join()
os.system(f"grep ^VmRSS /proc/{os.getpid()}/status")
for n in range(1000):
 timer = threading.Timer(5, None)
 timer.start()
 timer.cancel()
 timer.join()
os.system(f"grep ^VmRSS /proc/{os.getpid()}/status")
---
Output on Linux with the main branch of Python (3.11):
---
VmRSS:	 10924 kB
VmRSS:	 11104 kB
VmRSS:	 11104 kB
---
History
Date User Action Args
2021年09月24日 15:51:58vstinnersetrecipients: + vstinner, martin.panter, fengjiang
2021年09月24日 15:51:58vstinnersetmessageid: <1632498718.77.0.189923182595.issue43050@roundup.psfhosted.org>
2021年09月24日 15:51:58vstinnerlinkissue43050 messages
2021年09月24日 15:51:58vstinnercreate

AltStyle によって変換されたページ (->オリジナル) /