Skip to content

BUG: fix issues with newaxis and linalg.solve in numpy.array_api #25146

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

Merged
merged 1 commit into from
Nov 14, 2023

Conversation

rgommers
Copy link
Member

Looks like this wasn't caught before because of gaps in the test coverage (fixed for linalg.solve and fix ready to merge for newaxis in array-api-tests).

[skip azp] [skip cirrus] [skip circle]

@rgommers
Copy link
Member Author

The failure in the OpenSUSE BLAS job is unrelated; I'll have a look at that.

with errstate(call=_raise_linalgerror_singular, invalid='call',
over='ignore', divide='ignore', under='ignore'):
r = gufunc(a, b, signature=signature, extobj=extobj)
with np.errstate(call=_raise_linalgerror_singular, invalid='call',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting that the errstate removal did make it? Anyay, LGTM, thanks.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the implementation here was added before this was thoroughly tested in the test suite. Maybe the errstate import was removed and that went unnoticed due to incomplete test coverage.

@seberg seberg merged commit 0f61000 into numpy:main Nov 14, 2023
@rgommers rgommers deleted the array-api-fixes branch November 14, 2023 15:45
@@ -125,7 +125,7 @@

__all__ = ["__array_api_version__"]

from ._constants import e, inf, nan, pi
from ._constants import e, inf, nan, pi, newaxis

__all__ += ["e", "inf", "nan", "pi"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be added here as well.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make a PR?

@charris charris removed the 09 - Backport-Candidate PRs tagged should be backported label Nov 20, 2023
rgommers added a commit to rgommers/numpy that referenced this pull request Jan 18, 2024
Follows up on a post-merge comment in numpygh-25146.

[skip ci]
charris pushed a commit to charris/numpy that referenced this pull request Jan 18, 2024
Follows up on a post-merge comment in numpygh-25146.

[skip ci]
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.

4 participants