abess-team / abess

Fast Best-Subset Selection Library
https://abess.readthedocs.io/
Other
474 stars 41 forks source link

Installation Error: Could not find a version that satisfies the requirement setuptools>=42 #475

Closed chenpnn closed 1 year ago

chenpnn commented 1 year ago

Installation Error

When I try to install abess from GitHub directly using the command

cd ./python
pip install .

some errors were reported as shown in the following picture

eb959d4b4b8fd66db4e482f33704238

Is there anything wrong with my computer or the source code of abess?

Thanks!

Mamba413 commented 1 year ago

@chenpnn ,can you paste the Error information here rather than using screenshot? Also, can you provide some information for your python environment?

chenpnn commented 1 year ago

@Mamba413 Thanks for your reply, the installation error is shown as follows:

Processing d:\github\abess\python
  Installing build dependencies ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\Users\cp\Anaconda3\python.exe' 'C:\Users\cp\Anaconda3\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\cp\AppData\Local\Temp\pip-build-env-dk8isntj\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=42' wheel 'pybind11>=2.8.0' oldest-supported-numpy
       cwd: None
  Complete output (8 lines):
  WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))': /simple/setuptools/
  WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))': /simple/setuptools/
  WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))': /simple/setuptools/
  WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))': /simple/setuptools/
  WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))': /simple/setuptools/
  Could not fetch URL https://pypi.org/simple/setuptools/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/setuptools/ (Caused by SSLError(SSLError(1, '[SSL: KRB5_S_TKT_NYV] unexpected eof while reading (_ssl.c:1091)'))) - skipping
  ERROR: Could not find a version that satisfies the requirement setuptools>=42
  ERROR: No matching distribution found for setuptools>=42
  ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Users\cp\Anaconda3\python.exe' 'C:\Users\cp\Anaconda3\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\cp\AppData\Local\Temp\pip-build-env-dk8isntj\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=42' wheel 'pybind11>=2.8.0' oldest-supported-numpy Check the logs for full command output.

This error was reported when I tried to directly install abess using the source code cloned from GitHub in a new virtual environment (with no other packages installed), which was created by conda. Also, the version of Python is 3.9.1.

Mamba413 commented 1 year ago

@chenpnn ,it seems that setuptools>=42 is not support by Python 3.9.1? Can you make another python environment and try it again?

Mamba413 commented 1 year ago

@oooo26 , can you recommend you python version to @chenpnn

oooo26 commented 1 year ago

Hi @chenpnn, could you please try to install by another pip source like pip install . -i https://pypi.tuna.tsinghua.edu.cn/simple? Because the SSLError seems a network problem.

oooo26 commented 1 year ago

Besides, when I create a new environment with conda create -n py391 python=3.9.1, it has already included setuptools-65.6.3 and shows no problem on installation.

And by the way, a completely new environment maybe fail on compiling the latest abess. Please make sure these tools have been installed.

chenpnn commented 1 year ago

Hi @chenpnn, could you please try to install by another pip source like pip install . -i https://pypi.tuna.tsinghua.edu.cn/simple? Because the SSLError seems a network problem.

Thanks, this method works for me!