繁体   English   中英

heroku推送错误python 3-6

[英]heroku push error python 3-6

我在将Python代码发布到heroku时遇到问题,请记住,这是我在heroku上的第一个项目,并且首先与存储库有关

Counting objects: 18, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (16/16), done.
Writing objects: 100% (18/18), 21.80 KiB | 0 bytes/s, done.
Total 18 (delta 2), 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.5 (you are using python-3.6, which is unsupported).
remote:  !     We recommend upgrading by specifying the latest version (python-3.6.5).
remote:        Learn More: https://devcenter.heroku.com/articles/python-runtimes
remote: -----> Installing python-3.6
remote:  !     Requested runtime (python-3.6) 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 project.
remote:
To https://git.heroku.com/project.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/project.git'

尝试这个

 pipenv lock git add. git commit -am "make it better" git push heroku master 

如果要使用其他版本,请编辑新文件并在以下位置输入信息:[requires] python_version =“ 2.7”或[requires] python_full_version =“ 2.7.15”

您的requirements.txt文件必须包含python-3.6.5所有小写​​字母-符号很重要

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM