2

C:\Users\acc\Desktop\coding>python manage.py syncdb

Traceback (most recent call last):

File "manage.py", line 10, in

execute_from_command_line(sys.argv)

File "C:\Python27\lib\site-packages\django\core\management__init__.py", line 399, in execute_from_command_line

utility.execute()

File "C:\Python27\lib\site-packages\django\core\management__init__.py", line 392, in execute self.fetch_command(subcommand).run_from_argv(self.argv)

File "C:\Python27\lib\site-packages\django\core\management\base.py", line 242, in run_from_argv

self.execute(*args, **options.__dict__)

File "C:\Python27\lib\site-packages\django\core\management\base.py", line 280, in execute

translation.activate('en-us')

File "C:\Python27\lib\site-packages\django\utils\translation__init__.py", lin e 130, in activate

return _trans.activate(language)

File "C:\Python27\lib\site-packages\django\utils\translation\trans_real.py", l ine 188, in activate

_active.value = translation(language)

File "C:\Python27\lib\site-packages\django\utils\translation\trans_real.py", l ine 177, in translation default_translation = _fetch(settings.LANGUAGE_CODE)

File "C:\Python27\lib\site-packages\django\utils\translation\trans_real.py", l ine 158, in _fetch

for appname in reversed(settings.INSTALLED_APPS):

TypeError: argument to reversed() must be a sequence

please give me advice for removing this bug...

2
  • So, what is the value of INSTALLED_APPS? Commented Apr 5, 2014 at 8:56
  • @Daniel Roseman INSTALLED_APPS={ 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.admin', 'django.contrib.admindocs', } Commented Apr 5, 2014 at 9:14

1 Answer 1

2

You've made INSTALLED_APPS a set instead of a tuple. It should have parentheses, not curly brackets.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.