1. 首页
  2. IT资讯

flask web app部署到 heroku时,提示python 版本不兼容。heroku仅支持python3.6.3?

我的flask web APP 虚拟环境是python 3.5.3;
runtime.txt:python3.5.3;requirements.txt和 Procfile文件都有;执行pip install -r requirements.txt没有报错。
然而当我使用命令:git push heroku master 部署时出现:
…..
—>Python app detected

The lastest version of python 3 is python-3.6.3(you are using Python-2.7.13,which is unsupported).
We recommend upgrading by specifying the latest version(python-3.6.3).
Learn more:https//devcenter.heroku.com/articles/python-runtimes

—>Installing Python-2.7.13

Requested runtime (Python-2.7.13) is not available for this stack(heroku-16).
Aborting. More info:https://devcenter.heroku.com/articles/python-support
Push failed
....

…..
请问这是怎么回事呢,我在这个虚拟环境中运行$:python -V, 确实显示的是python3.5.3,然后我改runtime.txt:python-3.6.3 还是报错,初次入坑 python flask web,请大家帮我看看,谢谢。

本文来自投稿,不代表程序员编程网立场,如若转载,请注明出处:http://www.cxybcw.com/199178.html

联系我们

13687733322

在线咨询:点击这里给我发消息

邮件:1877088071@qq.com

工作时间:周一至周五,9:30-18:30,节假日休息

QR code