2013-02-14 123 views
0

嗨夥計,所以我跟着GUID來部署Django的在Heroku這裏部署的Django到Heroku的

https://devcenter.heroku.com/articles/django

,但我的服務器保持與這個錯誤有什麼想法或方向是極大的讚賞崩潰在Heroku。

2013-02-12T19:27:40+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site- packages/django/utils/importlib.py", line 35, in import_module 
2013-02-12T19:27:40+00:00 app[web.1]:  __import__(name) 
2013-02-12T19:27:40+00:00 app[web.1]: File "/app/eduudle/settings.py", line 15, in <module> 
2013-02-12T19:27:40+00:00 app[web.1]:  DATABASES = { 'default': {dj_database_url.config()}} 
2013-02-12T19:27:40+00:00 app[web.1]: TypeError: unhashable type: 'dict' 
2013-02-12T19:27:41+00:00 heroku[web.1]: Process exited with status 1 
2013-02-12T19:27:41+00:00 heroku[web.1]: State changed from starting to crashed 

回答

0

發現該文件的日期是這個問題,使下面的東西它基於不會工作這

https://github.com/heroku/heroku-buildpack-python/issues/45

我原本會的工作,但我加入了太多大括號

所以不是

DATABASES = { 'default': {dj_database_url.config()}} 

使用仍然不會工作

DATABASES = { 'default': dj_database_url.config()} 
1

docs建議爲數據庫格式應該是

DATABASES['default'] = dj_database_url.config()

DATABASES['default'] = {dj_database_url.config()}

+0

感謝但它把我放在正確的軌道上:) – exHash 2013-02-14 00:53:23