zyxue / ncbitax2lin

🐞 Convert NCBI taxonomy dump into lineages
MIT License
138 stars 29 forks source link

Error in installation #12

Closed zousm912zou closed 4 years ago

zousm912zou commented 4 years ago

Dear Xue,

Happy to use your project for lineage conversion. However, I encountered one problem about its installation in python 3.7. The error is below:

Very appreciate you could help resolve this issue.

Thank in advance!

Best regards.

WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ReadTimeoutError("HTTPSConnectionPool(host='pypi.org', port=443): Read timed out. (read timeout=15)")': /simple/ncbitax2lin/
Collecting ncbitax2lin
  Using cached ncbitax2lin-2.0.2-py3-none-any.whl (8.1 kB)
Requirement already satisfied, skipping upgrade: typing-extensions<4.0.0,>=3.7.4 in /gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages (from ncbitax2lin) (3.7.4.2)
Collecting fire<0.4.0,>=0.3.1
  Using cached fire-0.3.1.tar.gz (81 kB)
Collecting pandas<2.0.0,>=1.0.3
  Downloading pandas-1.0.3-cp37-cp37m-manylinux1_x86_64.whl (10.0 MB)
     |█▎                              | 409 kB 4.5 kB/s eta 0:35:18ERROR: Exception:
Traceback (most recent call last):
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 313, in recv_into
    return self.connection.recv_into(*args, **kwargs)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/OpenSSL/SSL.py", line 1822, in recv_into
    self._raise_ssl_error(self._ssl, result)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/OpenSSL/SSL.py", line 1622, in _raise_ssl_error
    raise WantReadError()
OpenSSL.SSL.WantReadError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 425, in _error_catcher
    yield
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 507, in read
    data = self._fp.read(amt) if not fp_closed else b""
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/cachecontrol/filewrapper.py", line 62, in read
    data = self.__fp.read(amt)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/http/client.py", line 447, in read
    n = self.readinto(b)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/http/client.py", line 491, in readinto
    n = self.fp.readinto(b)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/socket.py", line 589, in readinto
    return self._sock.recv_into(b)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 326, in recv_into
    raise timeout("The read operation timed out")
socket.timeout: The read operation timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 188, in _main
    status = self.run(options, args)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/cli/req_command.py", line 185, in wrapper
    return func(self, options, args)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/commands/install.py", line 333, in run
    reqs, check_supported_wheels=not options.target_dir
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 179, in resolve
    discovered_reqs.extend(self._resolve_one(requirement_set, req))
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 362, in _resolve_one
    abstract_dist = self._get_abstract_dist_for(req_to_install)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 314, in _get_abstract_dist_for
    abstract_dist = self.preparer.prepare_linked_requirement(req)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 412, in prepare_linked_requirement
    hashes=hashes,
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 198, in unpack_url
    hashes=hashes,
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 124, in get_http_url
    link, downloader, temp_dir.path, hashes
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 220, in _download_http_url
    for chunk in download.chunks:
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/cli/progress_bars.py", line 166, in iter
    for x in it:
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_internal/network/utils.py", line 39, in response_chunks
    decode_content=False,
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 564, in stream
    data = self.read(amt=amt, decode_content=decode_content)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 529, in read
    raise IncompleteRead(self._fp_bytes_read, self.length_remaining)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/contextlib.py", line 130, in __exit__
    self.gen.throw(type, value, traceback)
  File "/gss1/home/zsm20181019/anaconda3/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 430, in _error_catcher
    raise ReadTimeoutError(self._pool, None, "Read timed out.")
pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.
zousm912zou commented 4 years ago

And the python version is python 3.7.1

zyxue commented 4 years ago

It looks may be related to your network connection? Is it temporary?

Also, It would be better to use a virtual environment. Could you please try the following

conda create -n venv # or some other name you prefer
conda activate venv
pip install -U ncbitax2lin
zyxue commented 4 years ago

if the error persists, try

pip install -U --timeout 100 ncbitax2lin