Repository navigation
Conversation
virchan
reviewed
Mar 5, 2026
virchan
left a comment
Member
There was a problem hiding this comment.
Thank you for the PR, @repeating, and for helping improve scikit-learn.
I'm closing this PR per the Issues tagged "Needs Triage” section in the Contributing guide.
This was referenced Mar 5, 2026
Author
|
thanks for the heads up, appreciate the pointer — i'll make sure to only pick up triaged issues going forward. |
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.
closes #33219
the
traverse_upwardsfunction in_tree.pyxdoes boolean-indexed lookups on the condensed tree structured array:these always return shape-(1,) arrays, not scalars. numpy < 2.0 silently coerced shape-(1,) to scalar during cython typed assignment, but numpy 2.0 made this strict and raises
TypeError: only 0-dimensional arrays can be converted to Python scalars.the fix adds
[0]to both lookups to explicitly extract the scalar. this is always safe since each child node has exactly one parent in the condensed tree.added a non-regression test using the exact distance matrix from the issue.
AI usage disclosure
I used AI assistance for: