简体   繁体   中英

heroku installing python 3.6.2 instead of python 2.7

I have written a python 2.7 based flask app, however when I push it to heroku using git push heroku master i see in termonal that it installs python version 3.6.2 instead of python version 2.7.

how should I fix this and why is it picking python 3.6 ?

Newly created Python applications in heroku will be default to the Python 3.6.2 .. so if you want to specify a version of Python to be used to run your application.

This functionality is enabled by the presence of a runtime.txt file.

mohi@dev:~$ vi runtime.txt
mohi@dev:~$ cat runtime.txt
python-2.7.13

If you specify a different Python runtime than a previous build, your application's build cache will be purged.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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