#27366 closed Uncategorized (invalid)
KeyError: 'no_color' in base.py, l. 314
| Reported by: | Geoffrey R. | Owned by: | nobody |
|---|---|---|---|
| Component: | Migrations | Version: | 1.10 |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | yes | UI/UX: | no |
Description
Hello.
I played with Django Mezzanine http://mezzanine.jupo.org/ and when creating the database with the following settings:
USE_MODELTRANSLATION = True
LANGUAGE_CODE = 'en'
LANGUAGES = (
('en', _('English')),
('fr', _('French'))
)
and executing
python manage.py createdb
as mentionned on mezzanine's website, I get the following Traceback after having provided my login / email / pwd and saying that I want to translate fields:
[...]
Django-modeltranslation is installed for this project and you have specified to use i18n.
Would you like to update translation fields from the default ones? (yes/no): yes
Traceback (most recent call last):
File "manage.py", line 14, in <module>
execute_from_command_line(sys.argv)
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/django/core/management/__init__.py", line 367, in execute_from_command_line
utility.execute()
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/django/core/management/__init__.py", line 359, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/django/core/management/base.py", line 294, in run_from_argv
self.execute(*args, **cmd_options)
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/django/core/management/base.py", line 345, in execute
output = self.handle(*args, **options)
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/mezzanine/core/management/commands/createdb.py", line 61, in handle
func()
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/mezzanine/core/management/commands/createdb.py", line 151, in translation_fields
verbosity=self.verbosity, interactive=False)
File "/home/ge0/envs/bakadeshi/lib/python3.5/site-packages/django/core/management/base.py", line 314, in execute
if options['no_color']:
KeyError: 'no_color'
Python version: 3.5.2
Installed packages:
Mezzanine==4.2.2 django-modeltranslation
Change History (3)
follow-up: 3 comment:1 by , 9 years ago
| Resolution: | → invalid |
|---|---|
| Status: | new → closed |
comment:2 by , 9 years ago
I made a Pull Request on github to fix this issue: https://github.com/django/django/pull/7412
comment:3 by , 9 years ago
Replying to Tim Graham:
Django is likely not at fault, see :ticket:26315#comment:7.
Alright, I'll submit a patch to mezzanine then.
Sorry for the inconvenience.
Django is likely not at fault, see :ticket:26315#comment:7.