微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

django / python用于dajaxice的TEMPLATE_LOADER错误

我想使用django / djanxice并在setup.py,url.py等中设置它…

但是当我运行服务器时,会发生错误.

/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

解决方法:

来自django.template.loaders.eggs.Loader的.egg资源加载器使用setuptools软件包中的pkg_resources模块(如果可用).如果您的系统上没有pkg_resources,您将收到此异常.

setuptools是与Python解释器分开的安装.

您应该按照this link的说明安装setuptools.

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐