use*_*779 8 python django heroku
我正在尝试将Django应用程序推送到Heroku上,但是在运行git push heroku master时出现以下错误
Counting objects: 80, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (74/74), done.
Writing objects: 100% (80/80), 990.21 KiB | 0 bytes/s, done.
Total 80 (delta 20), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Python app detected
remote: ! The latest version of Python 2 is python-2.7.14 (you are using
python-2.7.12, which is unsupported).
remote: ! We recommend upgrading by specifying the latest version
(python-2.7.14).
remote: Learn More: https://devcenter.heroku.com/articles/python-
runtimes
remote: -----> Installing python-2.7.12
remote: -----> Installing pip
remote: -----> Installing requirements with pip
remote: Collecting alabaster==0.7.7 (from -r
/tmp/build_a1f6d188f9e0e61e01076a73d4e10542/requirements.txt (line 1))
remote: Downloading alabaster-0.7.7-py2.py3-none-any.whl
remote: Collecting anaconda-client==1.4.0 (from -r
/tmp/build_a1f6d188f9e0e61e01076a73d4e10542/requirements.txt (line 2))
remote: Could not find a version that satisfies the requirement
anaconda-client==1.4.0 (from -r
/tmp/build_a1f6d188f9e0e61e01076a73d4e10542/requirements.txt (line 2)) (from
versions: 1.1.1, 1.2.2)
remote: No matching distribution found for anaconda-client==1.4.0 (from
-r /tmp/build_a1f6d188f9e0e61e01076a73d4e10542/requirements.txt (line 2))
remote: ! Push rejected, failed to compile Python app.
remote:
remote: ! Push failed
remote: Verifying deploy...
remote:
remote: ! Push rejected to demo-freshstart.
Run Code Online (Sandbox Code Playgroud)
好像它与Anaconda有关,但我在我的requirements.txt中很早就看到了Anaconda,所以认为它可能只是因为其他原因而被赶上的第一件事.任何帮助将不胜感激.谢谢.
小智 5
您在conda中创建了环境吗?
如果是这样,则在激活环境后。您需要conda install pip来激活pip安装,否则冻结pip将返回到默认的anaconda环境。(这就是为什么您在那里看到它们的原因)
conda install pip
pip install django
)pip freeze > requirements.txt
请参见下面的神话5 https://jakevdp.github.io/blog/2016/08/25/conda-myths-and-misconceptions/
归档时间: |
|
查看次数: |
5867 次 |
最近记录: |