-
-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
BUG: f2py
still attempts to import numpy.distutils
on Python 3.12 when --fcompiler
option is specified.
#24838
Labels
Comments
5 tasks
Yeah, sorry, this should be simple to close, it should throw. @whophil, the correct usage now (should be documented as well) is to set the FC=gfortran f2py -c -m This will ensure |
15 tasks
HaoZeke
added a commit
to HaoZeke/numpy
that referenced
this issue
Nov 12, 2023
HaoZeke
added a commit
to HaoZeke/numpy
that referenced
this issue
Nov 19, 2023
HaoZeke
added a commit
to HaoZeke/numpy
that referenced
this issue
Nov 19, 2023
HaoZeke
added a commit
to HaoZeke/numpy
that referenced
this issue
Nov 22, 2023
rgommers
pushed a commit
that referenced
this issue
Nov 22, 2023
charris
pushed a commit
to charris/numpy
that referenced
this issue
Dec 19, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the issue:
f2py
implements some logic to use the meson backend automatically on Python 3.12, wherenumpy.distutils
no longer exists.However, when calling
f2py
with the--fcompiler
option,numpy.distutils
is still imported, which raisesImportError
when using runningf2py
with Python 3.12. This is due to the logic in these lines: https://github.com/numpy/numpy/blob/main/numpy/f2py/f2py2e.py#L608-L610If the
--fcompiler
is not supported with the meson backend, perhaps a more useful error message could be thrown earlier?Reproduce the code example:
Error message:
Runtime information:
Context for the issue:
No response
The text was updated successfully, but these errors were encountered: