当我尝试运行sudo ./manage.py runserver时,我得到以下错误:
Traceback (most recent call last): File "./manage.py",line 9,in <module> execute_from_command_line(sys.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py",line 429,in execute_from_command_line utility.execute() File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py",line 379,in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py",line 252,in fetch_command app_name = get_commands()[subcommand] File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py",line 101,in get_commands apps = settings.INSTALLED_APPS File "/usr/local/lib/python2.7/dist-packages/django/utils/functional.py",line 276,in __getattr__ self._setup() File "/usr/local/lib/python2.7/dist-packages/django/conf/__init__.py",line 42,in _setup self._wrapped = Settings(settings_module) File "/usr/local/lib/python2.7/dist-packages/django/conf/__init__.py",line 139,in __init__ logging_config_func(self.LOGGING) File "/usr/lib/python2.7/logging/config.py",line 776,in dictConfig dictConfigClass(config).configure() File "/usr/lib/python2.7/logging/config.py",line 562,in configure 'filter %r: %s' % (name,e)) ValueError: Unable to configure filter 'require_debug_false': Cannot resolve 'django.utils.log.requiredebugFalse': No module named requiredebugFalse
运行./manage.py runserver工作得很好.
做一点挖掘,我发现这可能与Django1.3错误有关?但是,我正在运行Django 1.4 pre-alpha的virtualenv.
我需要sudo命令的原因是因为我正在尝试从80端口运行服务器,这需要sudo.