wbalmer / backtracks

Python package to fit relative astrometry with background star motion tracks.
https://backtracks.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
6 stars 2 forks source link

readthedocs build error #30

Closed wbalmer closed 8 months ago

wbalmer commented 9 months ago

Hi @tomasstolker I've tried building on readthedocs by linking this github repo. It seems to be linked fine, but the builds are failing for some reason because the readthedocs install has some issue with pip installing orbitize!

This is what the build error says

` python -m pip install --exists-action=w --no-cache-dir -r requirements.txt Collecting astropy (from -r requirements.txt (line 1)) Downloading astropy-6.0.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (9.8 kB) Collecting astroquery (from -r requirements.txt (line 2)) Downloading astroquery-0.4.6-py3-none-any.whl (4.5 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.5/4.5 MB 8.1 MB/s eta 0:00:00 Collecting corner (from -r requirements.txt (line 3)) Downloading corner-2.2.2-py3-none-any.whl (15 kB) Collecting dynesty (from -r requirements.txt (line 4)) Downloading dynesty-2.1.3-py2.py3-none-any.whl.metadata (3.0 kB) Collecting matplotlib (from -r requirements.txt (line 5)) Downloading matplotlib-3.8.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (5.8 kB) Collecting numpy (from -r requirements.txt (line 6)) Downloading numpy-1.26.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (61 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 61.2/61.2 kB 5.6 MB/s eta 0:00:00 Collecting novas (from -r requirements.txt (line 7)) Downloading novas-3.1.1.5.tar.gz (135 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 135.3/135.3 kB 7.5 MB/s eta 0:00:00 Preparing metadata (setup.py): started Preparing metadata (setup.py): finished with status 'done' Collecting novas_de405 (from -r requirements.txt (line 8)) Downloading novas_de405-1997.1.tar.gz (55.0 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 55.0/55.0 MB 9.4 MB/s eta 0:00:00 Preparing metadata (setup.py): started Preparing metadata (setup.py): finished with status 'done' Collecting orbitize (from -r requirements.txt (line 9)) Downloading orbitize-2.2.2.tar.gz (10.6 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 10.6/10.6 MB 9.1 MB/s eta 0:00:00 Preparing metadata (setup.py): started Preparing metadata (setup.py): finished with status 'error' error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [6 lines of output] Traceback (most recent call last): File "", line 2, in File "", line 34, in File "/tmp/pip-install-5glzfcao/orbitize_ecd17e310c924258bedadf310eacf381/setup.py", line 2, in import numpy, sys ModuleNotFoundError: No module named 'numpy' [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed

× Encountered error while generating package metadata. ╰─> See above for output.

note: This is an issue with the package mentioned above, not pip. hint: See above for details. `

wbalmer commented 9 months ago

appears to be a problem with how setup.py is setup for orbitize and therefore in the virtual env that is created during readthedocs build. not sure i can fix this without a PR on orbitize

tomasstolker commented 9 months ago

Good idea to just copy the two functions from orbitize into backtrack!

I had the same problem when setting up the Actions workflow. Separately pip installing NumPy before orbitize did not help in that case, so not sure what the issue was.