[英]Heroku Deployment Issue - Python version
I have been working on a Django project that I am trying to deploy to Heroku. 我一直在尝试将其部署到Heroku的Django项目。 I've followed a tutorial from Python Crash Course.
我遵循了Python崩溃课程的教程。 When I enter git push heroku master, I get the following as a response:
当我输入git push heroku master时,得到以下响应:
Counting objects: 73, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (65/65), done.
Writing objects: 100% (73/73), 26.20 KiB | 0 bytes/s, done.
Total 73 (delta 8), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Python app detected
remote: ! The latest version of Python 3 is python-3.6.2 (you are using Python-2.7.12, which is unsupported).
remote: ! We recommend upgrading by specifying the latest version (python-3.6.2).
remote: Learn More: https://devcenter.heroku.com/articles/python-runtimes
remote: -----> Installing Python-2.7.12
remote: ! Requested runtime (Python-2.7.12) is not available for this stack (heroku-16).
remote: ! Aborting. More info: https://devcenter.heroku.com/articles/python-support
remote: ! Push rejected, failed to compile Python app.
remote:
remote: ! Push failed
remote: Verifying deploy...
remote:
remote: ! Push rejected to fathomless-scrubland-11916.
remote:
When I Python --version the cmd line returns 2.7.14 which is the most up-to-date version. 当我使用Python --version时,cmd行返回2.7.14,这是最新版本。 I feel like this error is telling me I need to use Python3 but their site says that 2.7.14 is supported as well.
我觉得这个错误告诉我我需要使用Python3,但是他们的网站说也支持2.7.14。 My runtime.txt specifies 2.7.14.
我的runtime.txt指定2.7.14。
请在runtime.txt中尝试python-3.5.2,尽管它给出了警告,但仍然可以使用
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.