1

当我尝试安装 Flask-Ask 时,出现以下错误。我如何解决它?

$ pip install flask-ask
Collecting flask-ask
Using cached Flask-Ask-0.9.8.tar.gz (40 kB)
ERROR: Command errored out with exit status 1:
 command: 'c:\users\loz99\appdata\local\programs\python\python38-32\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\loz99\\AppData\\Local\\Temp\\pip-install-kw14h5ho\\flask-ask\\setup.py'"'"'; __file__='"'"'C:\\Users\\loz99\\AppData\\Local\\Temp\\pip-install-kw14h5ho\\flask-ask\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\loz99\AppData\Local\Temp\pip-install-kw14h5ho\flask-ask\pip-egg-info'
     cwd: C:\Users\loz99\AppData\Local\Temp\pip-install-kw14h5ho\flask-ask\
Complete output (5 lines):
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\loz99\AppData\Local\Temp\pip-install-kw14h5ho\flask-ask\setup.py", line 8, in <module>
    from pip.req import parse_requirements
ModuleNotFoundError: No module named 'pip.req'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
4

3 回答 3

2

您的问题已得到解决,但该版本从未发布到 PyPi。

您可以尝试直接从 github 安装:

pip install https://github.com/johnwheeler/flask-ask/archive/master.zip
于 2020-02-18T15:35:31.063 回答
1

这是我找到的依赖项列表。这对于调试您的安装缺少的内容可能很有用。我在 Windows 10,Python 3.7.3

G:\Vid2\YTD>pip install git+https://github.com/johnwheeler/flask-ask.git@v0.8.8
Collecting git+https://github.com/johnwheeler/flask-ask.git@v0.8.8
  Cloning https://github.com/johnwheeler/flask-ask.git (to revision v0.8.8) to c:\users\raman\appdata\local\temp\pip-req-build-mr_0oxnv
  Running command git clone -q https://github.com/johnwheeler/flask-ask.git 'C:\Users\raman\AppData\Local\Temp\pip-req-build-mr_0oxnv'
  Running command git checkout -q 8fa6aa052a8a4b5273cbcceb48e926b41dbe8a32
Requirement already satisfied (use --upgrade to upgrade): Flask-Ask==0.8.8 from git+https://github.com/johnwheeler/flask-ask.git@v0.8.8 in c:\programdata\anaconda3\lib\site-p
ackages
Requirement already satisfied: Flask in c:\programdata\anaconda3\lib\site-packages (from Flask-Ask==0.8.8) (1.1.1)
Requirement already satisfied: pyOpenSSL in c:\programdata\anaconda3\lib\site-packages (from Flask-Ask==0.8.8) (19.0.0)
Requirement already satisfied: PyYAML in c:\programdata\anaconda3\lib\site-packages (from Flask-Ask==0.8.8) (5.1.1)
Requirement already satisfied: aniso8601 in c:\programdata\anaconda3\lib\site-packages (from Flask-Ask==0.8.8) (9.0.1)
Requirement already satisfied: six in c:\programdata\anaconda3\lib\site-packages (from Flask-Ask==0.8.8) (1.12.0)
Requirement already satisfied: Jinja2>=2.10.1 in c:\programdata\anaconda3\lib\site-packages (from Flask->Flask-Ask==0.8.8) (2.10.1)
Requirement already satisfied: itsdangerous>=0.24 in c:\programdata\anaconda3\lib\site-packages (from Flask->Flask-Ask==0.8.8) (1.1.0)
Requirement already satisfied: click>=5.1 in c:\programdata\anaconda3\lib\site-packages (from Flask->Flask-Ask==0.8.8) (7.0)
Requirement already satisfied: Werkzeug>=0.15 in c:\programdata\anaconda3\lib\site-packages (from Flask->Flask-Ask==0.8.8) (0.15.4)
Requirement already satisfied: cryptography>=2.3 in c:\programdata\anaconda3\lib\site-packages (from pyOpenSSL->Flask-Ask==0.8.8) (2.7)
Requirement already satisfied: MarkupSafe>=0.23 in c:\programdata\anaconda3\lib\site-packages (from Jinja2>=2.10.1->Flask->Flask-Ask==0.8.8) (1.1.1)
Requirement already satisfied: asn1crypto>=0.21.0 in c:\programdata\anaconda3\lib\site-packages (from cryptography>=2.3->pyOpenSSL->Flask-Ask==0.8.8) (0.24.0)
Requirement already satisfied: cffi!=1.11.3,>=1.8 in c:\programdata\anaconda3\lib\site-packages (from cryptography>=2.3->pyOpenSSL->Flask-Ask==0.8.8) (1.12.3)
Requirement already satisfied: pycparser in c:\programdata\anaconda3\lib\site-packages (from cffi!=1.11.3,>=1.8->cryptography>=2.3->pyOpenSSL->Flask-Ask==0.8.8) (2.19)
Building wheels for collected packages: Flask-Ask
  Building wheel for Flask-Ask (setup.py) ... done
  Stored in directory: C:\Users\raman\AppData\Local\Temp\pip-ephem-wheel-cache-y9row5ix\wheels\30\78\ac\......95909776
Successfully built Flask-Ask
于 2021-05-08T03:03:23.607 回答
-1

这对我有用:

pip install git+https://github.com/johnwheeler/flask-ask.git@v0.8.8
于 2020-09-25T04:56:28.027 回答