Я развертывал свой код на Heroku с git push heroku master
, но сборка не удалась. Вот вывод:
Counting objects: 316, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (305/305), done.
Writing objects: 100% (316/316), 12.71 MiB | 915.00 KiB/s, done.
Total 316 (delta 83), 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.4 (you are using Python 3.6.4, which is unsupported).
remote: ! We recommend upgrading by specifying the latest version (python-3.6.4).
remote: Learn More: https://devcenter.heroku.com/articles/python-runtimes
remote: -----> Installing Python 3.6.4
remote: ! Requested runtime (Python 3.6.4) 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 greensun.
remote:
To https://git.heroku.com/greensun.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/greensun.git'
Как видите, там написано:
пульт:! Последняя версия Python 3 - это python-3.6.4 (вы используете Python 3.6.4, который не поддерживается).
Как заставить Heroku распознавать Python 3.6.4? (он уже установлен на этот ноутбук с Ubuntu, и приложение имеет runtime.txt
с содержимым: python-3.6.4
).