mediadc icon indicating copy to clipboard operation
mediadc copied to clipboard

MediaDC fails to install numpy, pywavelets (Python 3.7)

Open svenb1234 opened this issue 2 years ago • 2 comments

Describe the bug MediaDC fails to install hexhamming with the error log below.

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior All needed packages should be installed.

Screenshots grafik

Configuration errors

Error during install pywt(pywavelets). Error: ERROR: Command errored out with exit status 1: command: /usr/bin/python3 /data/nextcloud/apps/mediadc/lib/Service/python/local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /tmp/tmp90q2_j1x cwd: /tmp/pip-install-z_jkk0cw/pywavelets_e13042a492914fa19b93df90616ba1b1 Complete output (22 lines): setup.py:366: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates warnings.warn("Unrecognized setuptools command, proceeding with " Traceback (most recent call last): File "/data/nextcloud/apps/mediadc/lib/Service/python/local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in main() File "/data/nextcloud/apps/mediadc/lib/Service/python/local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main json_out['return_val'] = hook(**hook_input['kwargs']) File "/data/nextcloud/apps/mediadc/lib/Service/python/local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 164, in prepare_metadata_for_build_wheel return hook(metadata_directory, config_settings) File "/usr/lib/python3/dist-packages/setuptools/build_meta.py", line 140, in prepare_metadata_for_build_wheel self.run_setup() File "/usr/lib/python3/dist-packages/setuptools/build_meta.py", line 211, in run_setup self).run_setup(setup_script=setup_script) File "/usr/lib/python3/dist-packages/setuptools/build_meta.py", line 126, in run_setup exec(compile(code, file, 'exec'), locals()) File "setup.py", line 478, in setup_package() File "setup.py", line 468, in setup_package ext_modules = get_ext_modules(USE_CYTHON) File "setup.py", line 182, in get_ext_modules from numpy import get_include as get_numpy_include ModuleNotFoundError: No module named 'numpy'

WARNING: Discarding https://files.pythonhosted.org/packages/35/e9/decd467448cde227aad94ff2976046afd3a51ad461ba9a325840687e8836/PyWavelets-1.2.0.tar.gz#sha256=6cbd69b047bb4e00873097472133425f5f08a4e6bc8b3f0ae709274d4d5e9a8d (from https://pypi.org/simple/pywavelets/) (requires-python:>=3.7). Command errored out with exit status 1: /usr/bin/python3 /data/nextcloud/apps/mediadc/lib/Service/python/local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_wheel /tmp/tmp90q2_j1x Check the logs for full command output.

Configuration errors

Error during install hexhamming(hexhamming). Error: ERROR: Command errored out with exit status 1: command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"'; file='"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-m21avhyg cwd: /tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/ Complete output (10 lines): running bdist_wheel running build running build_ext building 'hexhamming' extension creating build creating build/temp.linux-aarch64-3.7 creating build/temp.linux-aarch64-3.7/hexhamming aarch64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.7m -c hexhamming/python_hexhamming.cc -o build/temp.linux-aarch64-3.7/hexhamming/python_hexhamming.o -march=native unable to execute 'aarch64-linux-gnu-gcc': No such file or directory error: command 'aarch64-linux-gnu-gcc' failed with exit status 1

ERROR: Failed building wheel for hexhamming ERROR: Command errored out with exit status 1: command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"'; file='"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-5j1548i_/install-record.txt --single-version-externally-managed --user --prefix= --compile --install-headers /data/nextcloud/apps/mediadc/lib/Service/python/local/include/python3.7m/hexhamming cwd: /tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/ Complete output (10 lines): running install running build running build_ext building 'hexhamming' extension creating build creating build/temp.linux-aarch64-3.7 creating build/temp.linux-aarch64-3.7/hexhamming aarch64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.7m -c hexhamming/python_hexhamming.cc -o build/temp.linux-aarch64-3.7/hexhamming/python_hexhamming.o -march=native unable to execute 'aarch64-linux-gnu-gcc': No such file or directory error: command 'aarch64-linux-gnu-gcc' failed with exit status 1 ---------------------------------------- ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"'; file='"'"'/tmp/pip-install-xpuw_csw/hexhamming_8fddfc5d1a6c4aacb6e5706a64c64092/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-5j1548i_/install-record.txt --single-version-externally-managed --user --prefix= --compile --install-headers /data/nextcloud/apps/mediadc/lib/Service/python/local/include/python3.7m/hexhamming Check the logs for full command output.

Desktop (please complete the following information):

  • OS raspberry pi os buster image (docker image on raspberry pi os bullseye)
  • CPU (architecture) ARM raspberry pi 4
  • Browser [e.g. chrome, safari] Firefox
  • Nextcloud version [e.g. 22] 22
  • Database configuration (without sensitive information)
  • Python version [e.g. 3.9.1]: 3.7
  • MediaDC version [e.g. 0.1.0] 0.18

svenb1234 avatar Jan 11 '22 19:01 svenb1234

Can you somehow update python in docker to 3.8 version? Looks like these packages are not available for arm for python 3.7.

What i found from quick search is this article(it is for Ubuntu but may work for Debian): Ultimate Python installation on a Raspberry Pi & Ubuntu Script or Install Python 3.9 on Raspberry Pi OS or Debian 10 editing sources.list and upgrading it looks like a normal option.

If you do that(up your python), then remove local folder inside MediaDC app(or uninstall MediaDC(it will remove that folder), and then install again). Maybe it will work after that.

And you don't need hexhamming, currently it does nothing on arm, it is only for x64.

Another option is to wait probably a month or maybe two, we are working on universal solution for autoinstall for Arm, that will not require even a python in system.

bigcat88 avatar Jan 11 '22 20:01 bigcat88

@svenb1234 can you please provide a link to docker image you use? We will look at it closer, after that.

bigcat88 avatar Feb 02 '22 18:02 bigcat88

@svenb1234 if you still have this problem you can try new beta #91

bigcat88 avatar Dec 04 '22 10:12 bigcat88