‘resource_tracker.py’ warns for multiple leaked objects even if only single leak during multiprocessing
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 77.2k
- Forks
- 35.9k
- PR merge metrics
- PR metrics pending
Description
Bug report
Bug description:
If there is one object memory leak, the resource_tracker.py warns of multiple leaks which is a misleading description of the multiprocessing error in single cases:
warnings.warn('resource_tracker: There appear to be %d leaked %s objects to clean up at shutdown (len(rtype_cache), rtype))
The language in the warning should not assume there are multiple leaks.
CPython versions tested on:
3.11
Operating systems tested on:
Linux
Linked PRs
- gh-119558
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in resource_tracker.py at the warning shown in the issue and inspect how the cached resource count is used in its message. Update the wording so it remains accurate for both one and multiple leaked objects, then verify the warning behavior against the existing multiprocessing coverage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 30/100