TYP: ``arg{min,max}`` shape-typing by jorenham · Pull Request #31166 · numpy/numpy · GitHub
Skip to content

TYP: arg{min,max} shape-typing - #31166

Merged
charris merged 3 commits into
numpy:mainfrom
jorenham:typing/argmin-argmax
Apr 7, 2026
Merged

charris merged 3 commits into
numpy:mainfrom
jorenham:typing/argmin-argmax

Conversation

@jorenham

@jorenham jorenham commented Apr 6, 2026

Copy link
Copy Markdown
Member

Dual to #31163, this improves the shape-typing of

  • np.arg{min,max}
  • np.ndarray.arg{min,max}
  • np.ma.MaskedArray.arg{min,max}

AI Disclosure

N/A

@jorenham jorenham added this to the 2.5.0 Release milestone Apr 6, 2026
@github-actions

github-actions Bot commented Apr 6, 2026

Copy link
Copy Markdown

@jorenham

jorenham commented Apr 6, 2026

Copy link
Copy Markdown
Member Author

The primer errors for pandas are correct: np.intp and builtins.int are incompatible types, so this is a typing issue in pandas.

@charris
charris merged commit 282d065 into numpy:main Apr 7, 2026
15 checks passed
@charris

charris commented Apr 7, 2026

Copy link
Copy Markdown
Member

@jorenham
jorenham deleted the typing/argmin-argmax branch April 7, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants