Skip to content
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

The docs don't build with numpy 2.0 #21

Open
martinburchell opened this issue Jul 15, 2024 · 1 comment
Open

The docs don't build with numpy 2.0 #21

martinburchell opened this issue Jul 15, 2024 · 1 comment

Comments

@martinburchell
Copy link
Collaborator

martinburchell commented Jul 15, 2024

I pinned NumPy to <2.0 in d56e383 because of this error when building the docs:


Warning, treated as error:
autodoc: failed to import module 'treatment_resistant_depression' from module 'cardinal_pythonlib.psychiatry'; the following exception was raised:
cannot import name 'NaN' from 'numpy' (/home/runner/venv/lib/python3.10/site-packages/numpy/__init__.py)
make: *** [Makefile:20: html] Error 2
The name of the builder is: htmlDeleting directory '/home/runner/work/pythonlib/pythonlib/docs/build/html'
Making HTML version of documentation
Traceback (most recent call last):
  File "/home/runner/work/pythonlib/pythonlib/docs/./rebuild_docs.py", line 62, in <module>
    subprocess.check_call(cmdargs)
  File "/usr/lib/python3.10/subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['make', 'html', 'SPHINXOPTS="-W"']' returned non-zero exit status 2.
@RudolfCardinal
Copy link
Owner

Was going to update, but numpy==2.0.0 is quite new and not yet supported by scipy (https://docs.scipy.org/doc/scipy/dev/toolchain.html). Not sure about numba. When the time comes, helpful guide at https://numpy.org/devdocs/numpy_2_0_migration_guide.html.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants