Open zly20129 opened 1 month ago
It seems like your system is unable to connect to pypi.org and pythonhosted.org. Could you please check if that is the case? We need to get packages from there
It seems like your system is unable to connect to pypi.org and pythonhosted.org. Could you please check if that is the case? We need to get packages from there
I've been going crazy!!!
I've tried a manual bare metal install, an install script install, and a docker install, and so far it looks like docker is the most likely way to install successfully.
But currently docker installation is also stuck on network issues, here is the error log.
I'm in China, and as you know, for some reason, there are strict network controls on foreign service providers, which is really unfriendly to us Chinese users.(我在中国,你知道的,因为一些原因,对国外服务商采取了严格的网络管控,这对我们中国用户实再是太不友好了。)
zly@zly-virtual-machine:~/inventree/contrib/container$ docker compose run --rm inventree-server invoke update WARN[0000] /home/zly/inventree/contrib/container/docker-compose.yml:
version` is obsolete
[+] Creating 1/0
✔ Container inventree-db Running 0.0s
Loading config file : /home/inventree/data/config.yaml
Installing required python packages from 'src/backend/requirements.txt'
Requirement already satisfied: pip in /usr/local/lib/python3.11/site-packages (24.0)
Collecting pip
Downloading pip-24.1.2-py3-none-any.whl.metadata (3.6 kB)
Requirement already satisfied: setuptools in /root/.local/lib/python3.11/site-packages (69.5.1)
Collecting setuptools
Downloading setuptools-71.0.4-py3-none-any.whl.metadata (6.5 kB)
Downloading pip-24.1.2-py3-none-any.whl (1.8 MB)
━━ 0.1/1.8 MB 65.4 kB/s eta 0:00:27
ERROR: Exception:
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 438, in _error_catcher
yield
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 561, in read
data = self._fp_read(amt) if not fp_closed else b""
^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 527, in _fp_read
return self._fp.read(amt) if amt is not None else self._fp.read()
^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/http/client.py", line 473, in read
s = self.fp.read(amt)
^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/socket.py", line 706, in readinto
return self._sock.recv_into(b)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/ssl.py", line 1314, in recv_into
return self.read(nbytes, buffer)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/ssl.py", line 1166, in read
return self._sslobj.read(len, buffer)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TimeoutError: The read operation timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/usr/local/lib/python3.11/site-packages/pip/_internal/cli/base_command.py", line 180, in exc_logging_wrapper status = run_func(*args) ^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pip/_internal/cli/req_command.py", line 245, in wrapper return func(self, options, args) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pip/_internal/commands/install.py", line 377, in run requirement_set = resolver.resolve( ^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pip/_internal/resolution/resolvelib/resolver.py", line 179, in resolve self.factory.preparer.prepare_linked_requirements_more(reqs) File "/usr/local/lib/python3.11/site-packages/pip/_internal/operations/prepare.py", line 552, in prepare_linked_requirements_more self._complete_partial_requirements( File "/usr/local/lib/python3.11/site-packages/pip/_internal/operations/prepare.py", line 467, in _complete_partialrequirements for link, (filepath, ) in batch_download: File "/usr/local/lib/python3.11/site-packages/pip/_internal/network/download.py", line 183, in call for chunk in chunks: File "/usr/local/lib/python3.11/site-packages/pip/_internal/cli/progress_bars.py", line 53, in _rich_progress_bar for chunk in iterable: File "/usr/local/lib/python3.11/site-packages/pip/_internal/network/utils.py", line 63, in response_chunks for chunk in response.raw.stream( File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 622, in stream data = self.read(amt=amt, decode_content=decode_content) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 560, in read with self._error_catcher(): File "/usr/local/lib/python3.11/contextlib.py", line 158, in exit self.gen.throw(typ, value, traceback) File "/usr/local/lib/python3.11/site-packages/pip/_vendor/urllib3/response.py", line 443, 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.`
It seems like your system is unable to connect to pypi.org and pythonhosted.org. Could you please check if that is the case? We need to get packages from there
Regarding the problem of not being able to access these URLs, I've tried a few ways of configuring proxies, such as configuring http and https + socks proxies in the GUI, and http_proxy = this way, but none of them allow it to be installed successfully. By the way, the proxy is built using v2rayn's LAN proxy mode, and ubuntu's own browser can already access Google, which means there is no problem with the proxy configuration. 关于访问不了这些网址的问题,我尝试了一些配置代理的方式,比如在图形界面配置http和https+socks代理,还有http_proxy =这种方式,但没有一个可以让它顺利安装成功。 顺便说一句,代理搭建采用的是v2rayn的局域网代理模式,ubuntu自带的浏览器已经可以访问谷歌了,这说明代理配置的没有问题。
I have just started reading up on your network situation in china. It seems like some unis provide pretty good mirrors. I will look into detecting if the installer is running in a restricted network and using the mirror instead
I have just started reading up on your network situation in china. It seems like some unis provide pretty good mirrors. I will look into detecting if the installer is running in a restricted network and using the mirror instead
I've tried changing pip mirror source but it doesn't do anything, I've tried ali source, tsinghua source, douban source, none of them work. 我已经试过换pip镜像源了,但它没有任何作用,我试过阿里源、清华源、豆瓣源,都不行。
I have just started reading up on your network situation in china. It seems like some unis provide pretty good mirrors. I will look into detecting if the installer is running in a restricted network and using the mirror instead
At first I considered whether it was a missing /opt/inventree/data and /etc/inventree/config.yaml, installer.sh doesn't seem to be able to create these files automatically. In response, I tried manually creating these paths and files and installing them later, but this did not get Inventree to work properly. 最开始的时候我还考虑过是否是/opt/inventree/data和/etc/inventree/config.yaml缺失的问题,installer.sh似乎不能自动创建这些文件。 对此,我尝试了手动创建这些路径和文件,而后再进行安装,但这并没有让Inventree正常运行。
Without pip working nothing else will run, that is the root of all problems.
Without pip working nothing else will run, that is the root of all problems.
Do you know how to set up a system level proxy for Ubuntu? My biggest problem right now is that I set up the proxy, but only desktop graphics programs seem to work. For example, the terminal, traceroute www.google.com, it doesn't reach the target IP at all. 请问您知道怎么为Ubuntu设置系统级代理吗? 我现在最大的问题是设置了代理,但似乎只有桌面图形程序可以用。 比如终端,traceroute www.google.com,它根本无法到达目标IP。
Without pip working nothing else will run, that is the root of all problems.
export http_proxy="http://proxy_ip:proxy_port" export https_proxy="http://proxy_ip:proxy_port" 99% of the ways I've searched are using the two commands above, but I still can't hit google's servers after using them. 我搜索到的99%方式是使用上述的两条指令,但使用后依旧无法命中google的服务器。
Can you try if one of these mirrors work: https://www.a-netz.de/blog/2019/11/software-development-in-china.html? Also can your machine connect to Github? Update checks will not work if that is not the case
Can you try if one of these mirrors work: https://www.a-netz.de/blog/2019/11/software-development-in-china.html? Also can your machine connect to Github? Update checks will not work if that is not the case
OMG... My machine can connect to github, but it is too sollow. There no mirrors help me to success install.
Can you try if one of these mirrors work: https://www.a-netz.de/blog/2019/11/software-development-in-china.html? Also can your machine connect to Github? Update checks will not work if that is not the case
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
I've replaced several sources with this command and the installation was unsuccessful.
我用这个指令更换过好几个源,安装都不成功。
I have to read up more to solve this
I have to read up more to solve this
Thank you very much for your help, I've given up on bare metal and linux installs and am currently trying docker installs, if it still fails to install then it just means I'm not meant to be with this project. 非常感谢您的帮助,我已经放弃裸机和linux安装了,目前正在尝试docker安装,如果它依旧安装失败,那只能说明我和这个项目没有缘分了。
I have to read up more to solve this
zly@zly-virtual-machine:~/inventree/contrib/container$ pip config get global.index-url https://mirrors.aliyun.com/pypi/simple/ zly@zly-virtual-machine:~/inventree/contrib/container$ sudo nano /etc/docker/daemon.json [sudo] zly 的密码:
Look at this, I queried through the command and the mirror source has been successfully changed.
Currently in the process of being installed.
Deployment Method
Steps to Reproduce
Describe the problem*
I try use installer.sh to install InvenTree on Ubuntu 20.04 Desktop, but it not work. I don't know problems why to occurrence.
Steps to Reproduce
sudo wget -O install.sh https://get.inventree.org
sudo bash install.sh
Relevant log output