Open rrobinett opened 5 months ago
This is happening because Ubuntu 24.04 is using Python 3.12, and the 2.6.8 release is not compatible. I just made a 2.6.9 release with the fixes for Python 3.12. You can try it now and hopefully get better results!
The installation still fails on this Ubuntu 24.04 LTS server:
@.***:~$ sudo pip3 install --break-system-packages digital_rf Collecting digital_rf Using cached digital_rf-2.6.9.tar.gz (1.2 MB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting h5py (from digital_rf) Using cached h5py-3.11.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (2.5 kB) Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (from digital_rf) (1.26.4) Requirement already satisfied: packaging in /usr/lib/python3/dist-packages (from digital_rf) (24.0) Requirement already satisfied: python-dateutil in /usr/lib/python3/dist-packages (from digital_rf) (2.8.2) Requirement already satisfied: pytz in /usr/lib/python3/dist-packages (from digital_rf) (2024.1) Requirement already satisfied: six in /usr/lib/python3/dist-packages (from digital_rf) (1.16.0) Collecting watchdog (from digital_rf) Using cached watchdog-4.0.1-py3-none-manylinux2014_x86_64.whl.metadata (37 kB) Using cached h5py-3.11.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (5.4 MB) Using cached watchdog-4.0.1-py3-none-manylinux2014_x86_64.whl (83 kB) Building wheels for collected packages: digital_rf Building wheel for digital_rf (pyproject.toml) ... error error: subprocess-exited-with-error
× Building wheel for digital_rf (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [43 lines of output] Failed to load config from /tmp/pip-install-dcnjxp5b/digital-rf_6b355dddc7494ba6a84345422433ddf8/pyproject.toml: 'tool' Try to load it from setup.cfg running bdist_wheel running build running build_py Failed to load config from /tmp/pip-install-dcnjxp5b/digital-rf_6b355dddc7494ba6a84345422433ddf8/pyproject.toml: 'tool' Try to load it from setup.cfg Failed to load config from /tmp/pip-install-dcnjxp5b/digital-rf_6b355dddc7494ba6a84345422433ddf8/pyproject.toml: 'tool'
On Fri, May 24, 2024 at 2:03 AM TheOperator @.***> wrote:
image.png (view on web) https://github.com/MITHaystack/digital_rf/assets/75934980/39534482-1c04-4844-bcb5-c193e98bc781
— Reply to this email directly, view it on GitHub https://github.com/MITHaystack/digital_rf/issues/58#issuecomment-2129009723, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFAQZBMAIGAXPDOAQJLVBDZD365PAVCNFSM6AAAAABIGJ64B6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRZGAYDSNZSGM . You are receiving this because you authored the thread.Message ID: @.***>
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
Clearly I have more work to do with the Python build tools. Until then, you can try installing using the conda-forge package which is my primary workflow, or as a last resort installing from source.
Thanks, but I'll just disable the feature in my SW which requires DRF support. I have about 100 user sites and I don't want to add complexity to the installation process. Please let me know if/when I can do a 'apt install DRF..
thanks,
Rob
On Wed, May 29, 2024 at 11:41 AM Ryan Volz @.***> wrote:
Clearly I have more work to do with the Python build tools. Until then, you can try installing using the conda-forge package https://github.com/MITHaystack/digital_rf?tab=readme-ov-file#using-conda-package which is my primary workflow, or as a last resort installing from source https://github.com/MITHaystack/digital_rf?tab=readme-ov-file#using-source-code-package .
— Reply to this email directly, view it on GitHub https://github.com/MITHaystack/digital_rf/issues/58#issuecomment-2138041036, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFAQZC6KIU24ZRHKL4GKEDZEYOMJAVCNFSM6AAAAABIGJ64B6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZYGA2DCMBTGY . You are receiving this because you authored the thread.Message ID: @.***>
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
I tried this in an Ubuntu 24.04 Docker container, and I got a similar output that was more illuminating:
Building wheels for collected packages: digital_rf
Building wheel for digital_rf (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for digital_rf (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [43 lines of output]
Failed to load config from /tmp/pip-install-3_hdi_z9/digital-rf_196dd17ba4c54cd5b0bc8f5e3ba3ada0/pyproject.toml: 'tool'
Try to load it from setup.cfg
running bdist_wheel
running build
running build_py
Failed to load config from /tmp/pip-install-3_hdi_z9/digital-rf_196dd17ba4c54cd5b0bc8f5e3ba3ada0/pyproject.toml: 'tool'
Try to load it from setup.cfg
Failed to load config from /tmp/pip-install-3_hdi_z9/digital-rf_196dd17ba4c54cd5b0bc8f5e3ba3ada0/pyproject.toml: 'tool'
Try to load it from setup.cfg
creating build
creating build/lib.linux-x86_64-cpython-312
creating build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/util.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/ringbuffer.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/digital_rf_deprecated_hdf5.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/list_drf.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/__init__.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/drf_command.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/_version.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/watchdog_drf.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/digital_metadata.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/mirror.py -> build/lib.linux-x86_64-cpython-312/digital_rf
copying digital_rf/digital_rf_hdf5.py -> build/lib.linux-x86_64-cpython-312/digital_rf
creating build/lib.linux-x86_64-cpython-312/gr_digital_rf
copying gr_digital_rf/vector.py -> build/lib.linux-x86_64-cpython-312/gr_digital_rf
copying gr_digital_rf/__init__.py -> build/lib.linux-x86_64-cpython-312/gr_digital_rf
copying gr_digital_rf/digital_rf_sink.py -> build/lib.linux-x86_64-cpython-312/gr_digital_rf
copying gr_digital_rf/digital_rf_source.py -> build/lib.linux-x86_64-cpython-312/gr_digital_rf
copying gr_digital_rf/raster.py -> build/lib.linux-x86_64-cpython-312/gr_digital_rf
UPDATING build/lib.linux-x86_64-cpython-312/digital_rf/_version.py
set build/lib.linux-x86_64-cpython-312/digital_rf/_version.py to '2.6.9'
running build_ext
INFO: pkg-config not installed. Defaulting to HDF5_ROOT="/usr"
building 'digital_rf._py_rf_write_hdf5' extension
creating build/temp.linux-x86_64-cpython-312
creating build/temp.linux-x86_64-cpython-312/lib
x86_64-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -I/tmp/pip-install-3_hdi_z9/digital-rf_196dd17ba4c54cd5b0bc8f5e3ba3ada0/include -I/usr/include/python3.12 -I/tmp/pip-build-env-c8h42f18/overlay/local/lib/python3.12/dist-packages/numpy/core/include -I/usr/include -I/opt/local/include -I/usr/local/include -c lib/py_rf_write_hdf5.c -o build/temp.linux-x86_64-cpython-312/lib/py_rf_write_hdf5.o
In file included from lib/py_rf_write_hdf5.c:24:
/tmp/pip-install-3_hdi_z9/digital-rf_196dd17ba4c54cd5b0bc8f5e3ba3ada0/include/digital_rf.h:46:10: fatal error: hdf5.h: No such file or directory
46 | #include "hdf5.h"
| ^~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for digital_rf
Failed to build digital_rf
ERROR: Could not build wheels for digital_rf, which is required to install pyproject.toml-based projects
I then had to apt install libhdf5-dev pkg-config
to have all of the necessary dependencies to complete the build. Can you ensure these non-Python external dependencies before running pip3 install digital_rf
?
wsprdaemon@rx888:~/wsprdaemon$ sudo pip3 install digital_rf error: externally-managed-environment
× This environment is externally managed ╰─> To install Python packages system-wide, try apt install python3-xyz, where xyz is the package you are trying to install.
If you wish to install a non-Debian-packaged Python package,
create a virtual environment using python3 -m venv path/to/venv.
Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
sure you have python3-full installed.
If you wish to install a non-Debian packaged Python application,
it may be easiest to use pipx install xyz, which will manage a
virtual environment for you. Make sure you have pipx installed.
See /usr/share/doc/python3.12/README.venv for more information.
note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages. hint: See PEP 668 for the detailed specification.
wsprdaemon@rx888:~/wsprdaemon$ sudo pip3 install digital_rf error: externally-managed-environment
I think you need to add --break-system-packages
as an override like it suggests, since I think the intention with wsprdaemon is indeed to install into the system Python environment instead of some sort of virtual environment. That's a choice that falls outside of Digital RF. Sorry for the confusion since I dropped that flag in my previous comment!
HI Ryan,
Thanks for your attention. I think I tried -break-system-packages, but I'll try it again later today.
Rob
On Tue, Jun 4, 2024 at 8:51 AM Ryan Volz @.***> wrote:
@.***:~/wsprdaemon$ sudo pip3 install digital_rf error: externally-managed-environment
I think you need to add --break-system-packages as an override like it suggests, since I think the intention with wsprdaemon is indeed to install into the system Python environment instead of some sort of virtual environment. That's a choice that falls outside of Digital RF. Sorry for the confusion since I dropped that flag in my previous comment!
— Reply to this email directly, view it on GitHub https://github.com/MITHaystack/digital_rf/issues/58#issuecomment-2147872924, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFAQZHH4NANS3MFVT4QH6TZFXO6RAVCNFSM6AAAAABIGJ64B6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBXHA3TEOJSGQ . You are receiving this because you authored the thread.Message ID: @.***>
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
--break-system-packages sounds pretty scary, I'm not sure I'm brave enough to do that. I'll wait for Rob :-)
I have added two of my collaborators to this thread. While implementing support for Debian 12 and Ubuntu 24.04 I have added several "--break-system-packages" in order to execute some of the Python packages used in my Wsprdaemon software. I think I tried "--break-system-packages" and got an internal error in the python program, but I've got a dozen debug projects and I don't remember the details....
Hi Ryan,
I just tried to install DRF on an Ubuntu 24.04 system with ' -break-system-packages' and got this error
Rob
...... creating build/temp.linux-x86_64-cpython-312/lib x8664-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -I/tmp/pip-install-34ubl04/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include -I/usr/include/python3.12 -I/tmp/pip-build-env-5qjn0la4/overlay/local/lib/python3.12/dist-packages/numpy/core/include -I/usr/include -I/opt/local/include -I/usr/local/include -c lib/py_rf_write_hdf5.c -o build/temp.linux-x86_64-cpython-312/lib/py_rf_write_hdf5.o In file included from lib/py_rf_write_hdf5.c:24:
/tmp/pip-install-34ubl04_/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include/digital_rf.h:46:10:
fatal error: hdf5.h: No such file or directory
46 | #include "hdf5.h"
| ^~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for digital_rf Failed to build digital_rf ERROR: Could not build wheels for digital_rf, which is required to install pyproject.toml-based projects
On Wed, Jun 5, 2024 at 2:26 PM Rob Robinett @.***> wrote:
I have added two of my collaborators to this thread. While implementing support for Debian 12 and Ubuntu 24.04 I have added several "--break-system-packages" in order to execute some of the Python packages used in my Wsprdaemon software. I think I tried "--break-system-packages" and got an internal error in the python program, but I've got a dozen debug projects and I don't remember the details....
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
Install libhdf5-dev with apt first.
On Jun 8, 2024, at 08:34, Rob Robinett @.***> wrote:
Hi Ryan,
I just tried to install DRF on an Ubuntu 24.04 system with ' -break-system-packages' and got this error
Rob
...... creating build/temp.linux-x86_64-cpython-312/lib x8664-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -I/tmp/pip-install-34ubl04/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include -I/usr/include/python3.12 -I/tmp/pip-build-env-5qjn0la4/overlay/local/lib/python3.12/dist-packages/numpy/core/include -I/usr/include -I/opt/local/include -I/usr/local/include -c lib/py_rf_write_hdf5.c -o build/temp.linux-x86_64-cpython-312/lib/py_rf_write_hdf5.o In file included from lib/py_rf_writehdf5.c:24: /tmp/pip-install-34ubl04/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include/digital_rf.h:46:10: fatal error: hdf5.h: No such file or directory 46 | #include "hdf5.h" | ^
~~~ compilation terminated. error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 [end of output]note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for digital_rf Failed to build digital_rf ERROR: Could not build wheels for digital_rf, which is required to install pyproject.toml-based projects
On Wed, Jun 5, 2024 at 2:26 PM Rob Robinett @. @.>> wrote:
I have added two of my collaborators to this thread. While implementing support for Debian 12 and Ubuntu 24.04 I have added several "--break-system-packages" in order to execute some of the Python packages used in my Wsprdaemon software. I think I tried "--break-system-packages" and got an internal error in the python program, but I've got a dozen debug projects and I don't remember the details....
-- Rob Robinett AI6VN @. @.> mobile: +1 650 218 8896
Thank you Michael and Ryan, installation works on 24.04. So to summarize, on DRF can be installed and run on Ubuntu 24.04 with the addition of ' -break-system-packages' on the pip3 command line and 'apt install libhdf5-dev'
On Sat, Jun 8, 2024 at 6:37 AM Michael James Hauan @.***> wrote:
Install libhdf5-dev with apt first.
On Jun 8, 2024, at 08:34, Rob Robinett @.***> wrote:
Hi Ryan,
I just tried to install DRF on an Ubuntu 24.04 system with ' -break-system-packages' and got this error
Rob
...... creating build/temp.linux-x86_64-cpython-312/lib x8664-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -I/tmp/pip-install-34ubl04/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include -I/usr/include/python3.12 -I/tmp/pip-build-env-5qjn0la4/overlay/local/lib/python3.12/dist-packages/numpy/core/include -I/usr/include -I/opt/local/include -I/usr/local/include -c lib/py_rf_write_hdf5.c -o build/temp.linux-x86_64-cpython-312/lib/py_rf_write_hdf5.o In file included from lib/py_rf_write_hdf5.c:24:
/tmp/pip-install-34ubl04_/digital-rf_0446170ae2a743639aad2bdf4bdc4ef4/include/digital_rf.h:46:10: fatal error: hdf5.h: No such file or directory 46 | #include "hdf5.h" | ^
~~~ compilation terminated. error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1 [end of output]note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for digital_rf Failed to build digital_rf ERROR: Could not build wheels for digital_rf, which is required to install pyproject.toml-based projects
On Wed, Jun 5, 2024 at 2:26 PM Rob Robinett @.***> wrote:
I have added two of my collaborators to this thread. While implementing support for Debian 12 and Ubuntu 24.04 I have added several "--break-system-packages" in order to execute some of the Python packages used in my Wsprdaemon software. I think I tried "--break-system-packages" and got an internal error in the python program, but I've got a dozen debug projects and I don't remember the details....
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
-- Rob Robinett AI6VN @.*** mobile: +1 650 218 8896
I can't find DRF in the repo for Ubuntu 24.04 LTS and pip3 installation fails: