BUG: fix datetime/timedelta hash memory leak#29411
Merged
ngoldbaum merged 4 commits intonumpy:mainfrom Jul 24, 2025
Merged
Conversation
ngoldbaum
reviewed
Jul 22, 2025
Member
ngoldbaum
left a comment
There was a problem hiding this comment.
I noticed some preexisting issues with error handling and suggested a fix.
Also ping @walshb - FYI there were some error checking and reference counting bugs that were missed in the datetime/timedelta hash PR we merged last year.
ngoldbaum
reviewed
Jul 23, 2025
Co-authored-by: Nathan Goldbaum <[email protected]>
Co-authored-by: Nathan Goldbaum <[email protected]>
Contributor
Author
|
Seems to be in order. |
Member
|
Thanks for closing the loop on this @kostayScr. This will be backported to the 2.3 release branch and will be included in NumPy 2.3.2. |
charris
pushed a commit
to charris/numpy
that referenced
this pull request
Jul 24, 2025
* BUG: fix datetime/timedelta hash memory leak * get metadata directly from scalar object Co-authored-by: Nathan Goldbaum <[email protected]> * BUG: remove unnecessary Py_DECREF Co-authored-by: Nathan Goldbaum <[email protected]> * BUG: remove dtype variable declaration that is not used anymore --------- Co-authored-by: Nathan Goldbaum <[email protected]>
charris
added a commit
that referenced
this pull request
Jul 24, 2025
BUG: fix datetime/timedelta hash memory leak (#29411)
|
Is there any chance to get this back ported into the 2.2.x branch to fix usage with Python 3.10? |
Member
|
@scttstrck we could backport if it helps you, but we are not in the habit of making bug-fix releases for |
IndifferentArea
pushed a commit
to IndifferentArea/numpy
that referenced
this pull request
Dec 7, 2025
* BUG: fix datetime/timedelta hash memory leak * get metadata directly from scalar object Co-authored-by: Nathan Goldbaum <[email protected]> * BUG: remove unnecessary Py_DECREF Co-authored-by: Nathan Goldbaum <[email protected]> * BUG: remove dtype variable declaration that is not used anymore --------- Co-authored-by: Nathan Goldbaum <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes lack of a Py_DECREF() call in the datetime/timdelta hash function. Closes #29397.