Django makemessages命令生成权限被拒绝

时间:2014-01-21 12:38:37

标签: python django localization internationalization

当我运行此命令时 python manage.py makemessages -l ru -a 要构建.po文件,我看到了这样的错误

IOError: [Errno 13] Permission denied: './templates/base.html.py'

但我没有这个模板base.html.py我的模板目录中只有base.html(没有.py)。 请帮助我理解它是什么意思?

这是我的settings.py

import os
PROJECT_PATH = os.path.split(os.path.abspath(os.path.dirname(__file__)))[0]               
TEMPLATE_DIRS = ( os.path.join(PROJECT_PATH, "templates"), )   
DEBUG = True  
TEMPLATE_DEBUG = DEBUG   
gettext = lambda s: s   
LANGUAGES = ( ('ru', gettext('Russian')), ('en', gettext('English')), )
MODELTRANSLATION_DEFAULT_LANGUAGE = 'ru'  
TIME_ZONE = 'America/Chicago'   
LANGUAGE_CODE = 'ru'  
USE_I18N = True  
USE_L10N = True

我在控制台中看到的内容

./manage.py makemessages -l ru -a processing 
language ru 
IOError: [Errno 13] Permission denied: './templates/base.html.py'

0 个答案:

没有答案