mathurinm/celer

Building celer wheel when installing it as another package requirement fails, and installer must resort to setup.py install

mathurinm opened this issue · 4 comments

Stacktrace:

  ERROR: Command errored out with exit status 1:
   command: /home/mathurin/miniconda3/envs/pytorch/bin/python3.9 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-oltm2qzv/celer_8626cc01911b46be87b9b12b5dff228f/setup.py'"'"'; __file__='"'"'/tmp/pip-install-oltm2qzv/celer_8626cc01911b46be87b9b12b5dff228f/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-2sest4up
       cwd: /tmp/pip-install-oltm2qzv/celer_8626cc01911b46be87b9b12b5dff228f/
  Complete output (28 lines):
  /home/mathurin/miniconda3/envs/pytorch/lib/python3.9/site-packages/setuptools/dist.py:458: UserWarning: Normalizing '0.6.1dev' to '0.6.1.dev0'
    warnings.warn(tmpl.format(**locals()))
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.linux-x86_64-3.9
  creating build/lib.linux-x86_64-3.9/celer
  copying celer/homotopy.py -> build/lib.linux-x86_64-3.9/celer
  copying celer/__init__.py -> build/lib.linux-x86_64-3.9/celer
  copying celer/plot_utils.py -> build/lib.linux-x86_64-3.9/celer
  copying celer/dropin_sklearn.py -> build/lib.linux-x86_64-3.9/celer
  creating build/lib.linux-x86_64-3.9/celer/utils
  copying celer/utils/__init__.py -> build/lib.linux-x86_64-3.9/celer/utils
  copying celer/utils/testing.py -> build/lib.linux-x86_64-3.9/celer/utils
  creating build/lib.linux-x86_64-3.9/celer/datasets
  copying celer/datasets/ml_uci.py -> build/lib.linux-x86_64-3.9/celer/datasets
  copying celer/datasets/climate.py -> build/lib.linux-x86_64-3.9/celer/datasets
  copying celer/datasets/__init__.py -> build/lib.linux-x86_64-3.9/celer/datasets
  copying celer/datasets/libsvm.py -> build/lib.linux-x86_64-3.9/celer/datasets
  copying celer/datasets/simulated.py -> build/lib.linux-x86_64-3.9/celer/datasets
  running build_ext
  building 'celer.lasso_fast' extension
  creating build/temp.linux-x86_64-3.9
  creating build/temp.linux-x86_64-3.9/celer
  gcc -pthread -B /home/mathurin/miniconda3/envs/pytorch/compiler_compat -Wl,--sysroot=/ -Wno-unused-result -Wsign-compare -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /home/mathurin/miniconda3/envs/pytorch/include -fPIC -O2 -isystem /home/mathurin/miniconda3/envs/pytorch/include -fPIC -I/home/mathurin/miniconda3/envs/pytorch/lib/python3.9/site-packages/numpy/core/include -I/home/mathurin/miniconda3/envs/pytorch/include/python3.9 -c celer/lasso_fast.cpp -o build/temp.linux-x86_64-3.9/celer/lasso_fast.o -O3
  gcc: error: celer/lasso_fast.cpp: No such file or directory
  error: command '/usr/bin/gcc' failed with exit code 1
  ----------------------------------------
  ERROR: Failed building wheel for celer
  Running setup.py clean for celer
  Building wheel for libsvmdata (setup.py) ... done
  Created wheel for libsvmdata: filename=libsvmdata-0.1-py3-none-any.whl size=5225 sha256=ca6a78bf84339e706b2c83e6805ba73cb0a5cd2891cb091c0fc19c69b0e8dc69
  Stored in directory: /home/mathurin/.cache/pip/wheels/8d/b8/b7/218d4dee9627a44d704b7c438d9367bfbb830465bac43d8025
Successfully built libsvmdata
Failed to build celer
Installing collected packages: urllib3, idna, chardet, tqdm, threadpoolctl, requests, pytz, joblib, scikit-learn, pandas, download, xarray, seaborn, llvmlite, libsvmdata, Cython, numba, celer, iterreg
    Running setup.py install for celer ... done
  DEPRECATION: celer was installed using the legacy 'setup.py install' method, because a wheel could not be built for it. A possible replacement is to fix the wheel build issue reported above. You can find discussion regarding this at https://github.com/pypa/pip/issues/8368.

yet, trying to build celer's wheel locally with pip wheel ., I don't get any error. Puzzling.

same for me on Arch Linux.

Hi @wilecoyote2015,
It has not been a blocking issue for me so it's currently not high on the priority list. Is it blocking for you? Do you have any idea how to address it?

@mathurinm
I have been able to build the current master according to the build instructions provided in the readme, so it is not a blocking issue for me.
Besides, I have no real idea what causes the issue, unfortunately...

Upgrading pip to 21.2.4 and installing the wheel package, celer's wheel building when being installed as the dependency of another package works on my machine.

Building wheels for collected packages: celer
  Created temporary directory: /tmp/pip-wheel-2_wmqr31
  Building wheel for celer (setup.py) ...   Destination directory: /tmp/pip-wheel-2_wmqr31
  ....
    Created wheel for celer: filename=celer-0.6-cp38-cp38-linux_x86_64.whl size=2849347 sha256=bd7124a8663c1d530ffe59b456c239b47a20ff3b8396f827079cd7f1557bbbc1
  Stored in directory: /home/mathurin/.cache/pip/wheels/67/d9/07/95dca1614fb8f8c87f6851b663dfadb53f8846b5cd8ca0a698
Successfully built celer