Skip to content
This repository has been archived by the owner on Dec 19, 2023. It is now read-only.

docker-compose 启动失败: Could not find a version that satisfies the requirement ntplib==0.3.3 #772

Open
lsk-boy-f opened this issue Sep 8, 2020 · 5 comments

Comments

@lsk-boy-f
Copy link

描述问题

在Mac或者Ubuntu上,通过 docker-compose 启动项目失败

重现步骤

1. clone or downlaod project
2. 按需修改 TickerConfig.py
3. 执行 `docker-compose up --build` 

截图&日志

 ---> 4ccdc35c9228
Step 10/13 : COPY requirements-docker37.txt ./
 ---> Using cache
 ---> 5cc53a6c4263
Step 11/13 : RUN pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir -r requirements-docker37.txt
 ---> Running in f1c28d438bbb
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting bs4==0.0.1
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/10/ed/7e8b97591f6f456174139ec089c769f89a94a1a4025fe967691de971f314/bs4-0.0.1.tar.gz (1.1 kB)
Collecting requests==2.18.4
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/49/df/50aa1999ab9bde74656c2919d9c0c085fd2b3775fd3eca826012bef76d8c/requests-2.18.4-py2.py3-none-any.whl (88 kB)
Collecting Pillow
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/e8/f2/6722dd0c22e3a143ac792ccb2424924ac72af4adea756b1165b4cad50da7/Pillow-7.2.0-cp37-cp37m-manylinux1_x86_64.whl (2.2 MB)
Collecting wrapcache==1.0.8
  Downloading https://pypi.tuna.tsinghua.edu.cn/packages/39/5f/fee52c29d0887a0457f256d7503d2bea1ad3fe9d02d269b1374db400a757/wrapcache-1.0.8.zip (16 kB)
ERROR: Could not find a version that satisfies the requirement ntplib==0.3.3 (from -r requirements-docker37.txt (line 5)) (from versions: 0.3.4)
ERROR: No matching distribution found for ntplib==0.3.3 (from -r requirements-docker37.txt (line 5))
ERROR: Service 'ticket' failed to build: The command '/bin/sh -c pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir -r requirements-docker37.txt' returned a non-zero code: 1

环境信息

  • macOS 10.15.6
  • Docker version 19.03.8, build afacb8b
  • docker-compose version 1.25.5, build 8a1c60f6

or

  • Ubuntu 18.04.3 LTS
  • Docker version 19.03.5, build 633a0ea838
  • docker-compose version 1.25.0, build 0a186604

额外的备注

  • nothing
lsk-boy-f pushed a commit to lsk-boy-f/12306 that referenced this issue Sep 8, 2020
ntplib version not satisfy in docker
@cick
Copy link

cick commented Sep 9, 2020

其实就是个ntplib库更新了你需要把 ,你如果用本地安装就把requirements-docker37.txt 更改为ntplib==0.3.4

@lsk-boy-f
Copy link
Author

其实就是个ntplib库更新了你需要把 ,你如果用本地安装就把requirements-docker37.txt 更改为ntplib==0.3.4

是的,所以我顺带提了个pr,免得不熟悉的人爬坑了

@lizhecao
Copy link

谢谢,更新到0.3.4就可以了

@yuhal
Copy link

yuhal commented Jan 8, 2021

赞同@lizhecao,把 ntplib 的版本从0.3.3更新到0.3.4之后,可以正常启动。
从这两个文件中更改,requirements.txt 和 requirements-docker37.txt。

@shunkanghe
Copy link

多谢 各位大佬

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants