2012-10-18 23 views
4

我想使用Django/djanxice並在setup.py,url.py等設置它...Django的/ Python的TEMPLATE_LOADER錯誤dajaxice

但是當我運行的服務器,會出現誤差。

/Library/Python/2.7/site-packages/django/template/loader.py:113: UserWarning: Your TEMPLATE_LOADERS setting includes 'django.template.loaders.eggs.Loader', but your Python installation doesn't support that type of template loading. Consider removing that line from TEMPLATE_LOADERS. 
    warnings.warn("Your TEMPLATE_LOADERS setting includes %r, but your Python installation doesn't support that type of template loading. Consider removing that line from TEMPLATE_LOADERS." % loader) 
No handlers could be found for logger "dajaxice" 

我使用Google搜索,但找不到這樣的錯誤。

任何人都可以幫助爲什麼python安裝不支持這個Templat_Loaders?

我的Python版本是2.7.3,使用OS X v10.8

+0

你可以發佈你的settings.py(你設置dajaxice的部分)和urls.py嗎? –

回答

2

django.template.loaders.eggs.Loader.egg資源加載器使用pkg_resources模塊從setuptools包(如果可用)。如果pkg_resources在您的系統上不可用,您將得到此例外。

setuptools是一個與Python解釋器分開的安裝。

您應按照的說明安裝setuptools。