2012-10-12 76 views
1

我需要在Heroku上運行分發版本0.6.28。我更新了我的requirements.txt文件,但似乎沒有任何效果。如何在Heroku上升級分發包?

我想從需要這個更高版本的分發包的tarball中的模塊進行安裝。

在部署我只得到這樣的:

 Running setup.py egg_info for package from http://downloads.sourceforge.net/project/mysql-python/mysql-python-test/1.2.4b4/MySQL-python-1.2.4b4.tar.gz 
     The required version of distribute (>=0.6.28) is not available, 
     and can't be installed while this script is running. Please 
     install a more recent version first, using 
     'easy_install -U distribute'. 

     (Currently using distribute 0.6.27 (/tmp/build_ibj6h3in4vgp/.heroku/venv/lib/python2.7/site-packages/distribute-0.6.27-py2.7.egg)) 
     Complete output from command python setup.py egg_info: 
     The required version of distribute (>=0.6.28) is not available, 

回答

-1

嘗試增加與特定版本的依賴關係上的第一推分發,然後加入所需的依賴。

cat requirements.txt 
... 
distribute==0.6.28 
... 
git push heroku master 
... 
cat requirements.txt 
... 
your deps here 
+0

打我吧! – myusuf3

+0

除非它不起作用。 – skoczen

2

好的,這裏有一個解決方案,暫時工作。長期修復我認爲是Heroku升級其分發版本。

  1. 叉蟒蛇buildpack:https://github.com/heroku/heroku-buildpack-python/
  2. 添加你需要的包裝要求(我把它們放在斌/編譯,就像其他的點子之前安裝要求步驟)。有關該差異,請參見https://github.com/buildingenergy/heroku-buildpack-python/commit/12635e22aa3a3651f9bedb3b326e2cb4fd1d2a4b
  3. 更改buildpack爲您的應用程序:

    Heroku的配置:添加BUILDPACK_URL =混帳://github.com/heroku/heroku-buildpack-python.git

  4. 再推。它應該工作。