-
Notifications
You must be signed in to change notification settings - Fork 720
PR #35668: Bump numpy from 2.3.5 to 2.4.0 #35821
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
copybara-service
wants to merge
1
commit into
main
Choose a base branch
from
test_850730763
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+146
−150
Conversation
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
Imported from GitHub PR #35668 Bumps [numpy](https://github.com/numpy/numpy) from 2.3.5 to 2.4.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/numpy/numpy/releases">numpy's releases</a>.</em></p> <blockquote> <h2>2.4.0 (Dec 20, 2025)</h2> <h1>NumPy 2.4.0 Release Notes</h1> <p>The NumPy 2.4.0 release continues the work to improve free threaded Python support, user dtypes implementation, and annotations. There are many expired deprecations and bug fixes as well.</p> <p>This release supports Python versions 3.11-3.14</p> <h2>Highlights</h2> <p>Apart from annotations and <code>same_value</code> kwarg, the 2.4 highlights are mostly of interest to downstream developers. They should help in implementing new user dtypes.</p> <ul> <li>Many annotation improvements. In particular, runtime signature introspection.</li> <li>New <code>casting</code> kwarg <code>'same_value'</code> for casting by value.</li> <li>New <code>PyUFunc_AddLoopsFromSpec</code> function that can be used to add user sort loops using the <code>ArrayMethod</code> API.</li> <li>New <code>__numpy_dtype__</code> protocol.</li> </ul> <h2>Deprecations</h2> <h3>Setting the <code>strides</code> attribute is deprecated</h3> <p>Setting the strides attribute is now deprecated since mutating an array is unsafe if an array is shared, especially by multiple threads. As an alternative, you can create a new view (no copy) via:</p> <ul> <li><code>np.lib.stride_tricks.strided_window_view</code> if applicable,</li> <li><code>np.lib.stride_tricks.as_strided</code> for the general case,</li> <li>or the <code>np.ndarray</code> constructor (<code>buffer</code> is the original array) for a light-weight version.</li> </ul> <p>(<a href="https://redirect.github.com/numpy/numpy/pull/28925">gh-28925</a>)</p> <h3>Positional <code>out</code> argument to <code>np.maximum</code>, <code>np.minimum</code> is deprecated</h3> <p>Passing the output array <code>out</code> positionally to <code>numpy.maximum</code> and <code>numpy.minimum</code> is deprecated. For example, <code>np.maximum(a, b, c)</code> will emit a deprecation warning, since <code>c</code> is treated as the output buffer rather than a third input.</p> <p>Always pass the output with the keyword form, e.g. <code>np.maximum(a, b, out=c)</code>. This makes intent clear and simplifies type annotations.</p> <p>(<a href="https://redirect.github.com/numpy/numpy/pull/29052">gh-29052</a>)</p> <h3><code>align=</code> must be passed as boolean to <code>np.dtype()</code></h3> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/numpy/numpy/blob/main/doc/RELEASE_WALKTHROUGH.rst">numpy's changelog</a>.</em></p> <blockquote> <h2>Update 2.4.0 milestones</h2> <p>Look at the issues/prs with 2.4.0 milestones and either push them off to a later version, or maybe remove the milestone. You may need to add a milestone.</p> <h2>Check the numpy-release repo</h2> <p>The things to check are the <code>cibuildwheel</code> version in <code>.github/workflows/wheels.yml</code> and the <code>openblas</code> versions in <code>openblas_requirements.txt</code>.</p> <h1>Make a release PR</h1> <p>Four documents usually need to be updated or created for the release PR:</p> <ul> <li>The changelog</li> <li>The release notes</li> <li>The <code>.mailmap</code> file</li> <li>The <code>pyproject.toml</code> file</li> </ul> <p>These changes should be made in an ordinary PR against the maintenance branch. Other small, miscellaneous fixes may be part of this PR. The commit message might be something like::</p> <pre><code>REL: Prepare for the NumPy 2.4.0 release <ul> <li>Create 2.4.0-changelog.rst.</li> <li>Update 2.4.0-notes.rst.</li> <li>Update .mailmap.</li> <li>Update pyproject.toml<br /> </code></pre></li> </ul> <h2>Set the release version</h2> <p>Check the <code>pyproject.toml</code> file and set the release version and update the classifier if needed::</p> <pre><code>$ gvim pyproject.toml </code></pre> <h2>Check the <code>doc/source/release.rst</code> file</h2> <p>make sure that the release notes have an entry in the <code>release.rst</code> file::</p> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/numpy/numpy/commit/c5ab79c14c98bfda1e60770ffa23a6130f8267b7"><code>c5ab79c</code></a> Merge pull request <a href="https://redirect.github.com/numpy/numpy/issues/30487">#30487</a> from charris/prepare-2.4.0.2</li> <li><a href="https://github.com/numpy/numpy/commit/05e379a9c925dbeca59851b881c64ba098c5abab"><code>05e379a</code></a> REL: Prepare for the NumPy 2.4.0 release (2)</li> <li><a href="https://github.com/numpy/numpy/commit/485f1c40703f1c43be708be4c7b7a21b10d90337"><code>485f1c4</code></a> REL: Prepare for the NumPy 2.4.0 release (1) (<a href="https://redirect.github.com/numpy/numpy/issues/30486">#30486</a>)</li> <li><a href="https://github.com/numpy/numpy/commit/c683481c9bace3c6a3ba487f50b34539832377a8"><code>c683481</code></a> REL: Prepare for the NumPy 2.4.0 release (<a href="https://redirect.github.com/numpy/numpy/issues/30439">#30439</a>)</li> <li><a href="https://github.com/numpy/numpy/commit/11d9ed27e07637aa92b8d43bf2ad380a2b8c5c01"><code>11d9ed2</code></a> Merge pull request <a href="https://redirect.github.com/numpy/numpy/issues/30459">#30459</a> from charris/backport-30456</li> <li><a href="https://github.com/numpy/numpy/commit/2a17ddb25580f20f27c76327733449434c302032"><code>2a17ddb</code></a> TYP: restore <code>generic.__hash__</code> (<a href="https://redirect.github.com/numpy/numpy/issues/30456">#30456</a>)</li> <li><a href="https://github.com/numpy/numpy/commit/d04a4293bf8c8345f072891433ddb8c483785a6b"><code>d04a429</code></a> Merge pull request <a href="https://redirect.github.com/numpy/numpy/issues/30432">#30432</a> from charris/backport-30426</li> <li><a href="https://github.com/numpy/numpy/commit/f94a148bc07fd167275f167995edce57b4f0b8c5"><code>f94a148</code></a> fix more data races in mtrand.pyx (<a href="https://redirect.github.com/numpy/numpy/issues/30426">#30426</a>)</li> <li><a href="https://github.com/numpy/numpy/commit/06a9d4219291f5a15eed54de9314f72b74c41aed"><code>06a9d42</code></a> Merge pull request <a href="https://redirect.github.com/numpy/numpy/issues/30420">#30420</a> from charris/backport-30418</li> <li><a href="https://github.com/numpy/numpy/commit/30819cd952a4a92852d619b5dd720c63fbcab6bd"><code>30819cd</code></a> Merge pull request <a href="https://redirect.github.com/numpy/numpy/issues/30419">#30419</a> from charris/backport-30373</li> <li>Additional commits viewable in <a href="https://github.com/numpy/numpy/compare/v2.3.5...v2.4.0">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Copybara import of the project: -- c60ba63 by dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>: Bump numpy from 2.3.5 to 2.4.0 Bumps [numpy](https://github.com/numpy/numpy) from 2.3.5 to 2.4.0. - [Release notes](https://github.com/numpy/numpy/releases) - [Changelog](https://github.com/numpy/numpy/blob/main/doc/RELEASE_WALKTHROUGH.rst) - [Commits](numpy/numpy@v2.3.5...v2.4.0) --- updated-dependencies: - dependency-name: numpy dependency-version: 2.4.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Merging this change closes #35668 FUTURE_COPYBARA_INTEGRATE_REVIEW=#35668 from openxla:dependabot/pip/numpy-2.4.0 c60ba63 PiperOrigin-RevId: 850730763
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
None yet
0 participants
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.
PR #35668: Bump numpy from 2.3.5 to 2.4.0
Imported from GitHub PR #35668
Bumps numpy from 2.3.5 to 2.4.0.
Release notes
Sourced from numpy's releases.
... (truncated)
Changelog
Sourced from numpy's changelog.
... (truncated)
Commits
c5ab79cMerge pull request #30487 from charris/prepare-2.4.0.205e379aREL: Prepare for the NumPy 2.4.0 release (2)485f1c4REL: Prepare for the NumPy 2.4.0 release (1) (#30486)c683481REL: Prepare for the NumPy 2.4.0 release (#30439)11d9ed2Merge pull request #30459 from charris/backport-304562a17ddbTYP: restoregeneric.__hash__(#30456)d04a429Merge pull request #30432 from charris/backport-30426f94a148fix more data races in mtrand.pyx (#30426)06a9d42Merge pull request #30420 from charris/backport-3041830819cdMerge pull request #30419 from charris/backport-30373Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot mergewill merge this PR after your CI passes on it@dependabot squash and mergewill squash and merge this PR after your CI passes on it@dependabot cancel mergewill cancel a previously requested merge and block automerging@dependabot reopenwill reopen this PR if it is closed@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)--
c60ba63 by dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>:
Bump numpy from 2.3.5 to 2.4.0
Bumps numpy from 2.3.5 to 2.4.0.
updated-dependencies:
dependency-version: 2.4.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] support@github.com
Merging this change closes #35668
FUTURE_COPYBARA_INTEGRATE_REVIEW=#35668 from openxla:dependabot/pip/numpy-2.4.0 c60ba63