Everytime I deploy to heroku I get a Timeout error

落花浮王杯 提交于 2020-01-15 04:28:52

问题


I've been using Heroku for over a year now to deploy my Django app.

Suddenly though (without any major changes) everytime I push to Heroku, I'm getting the error, (Utils::TimeoutError)

 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:appname.git'

It happens everytime, but at different stages of installing all the packages in my requirements.txt file.

What could be causing this?


回答1:


The docs for the python build pack talk about this

Build Timeout

This is normally caused by a very large number of dependencies being installed at the same time.

Sometimes, this is caused by a Python interpreter upgrade. In this case, you have two options:

Add a runtime.txt file to your repository that specifies the existing version of python you're using (e.g. python-2.7.3). Learn more.

Install all of your dependencies again. I'd recommend pushing once with only half of your dependencies, then once again with all of them. Then you won't hit the timeout.

Once they are installed, they are cached, so you shouldn't run into this again.

You can see more here https://github.com/heroku/heroku-buildpack-python/wiki/Troubleshooting#build-timeout.



来源:https://stackoverflow.com/questions/16173467/everytime-i-deploy-to-heroku-i-get-a-timeout-error

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!