L
L
lemonchik372021-06-24 07:18:30
Django
lemonchik37, 2021-06-24 07:18:30

Why doesn't python manage.py makemigrations learning_logs work?

When typing the command in the terminal, I get the error
PS C:\Users\admin\Desktop\learning_log> python manage.py makemigretions learning_logs
Traceback (most recent call last):
File "C:\Users\admin\AppData\Local\Programs\Python\ Python39\lib\site-packages\django\core\management\__init__.py", line 237, in fetch_command
app_name = commands[subcommand]
KeyError: 'makemigretions'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users\admin\Desktop\learning_log\manage.py", line 22, in
main()
File "C:\Users\admin\Desktop\learning_log\manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\core\management\__init__.py", line 419, in execute_from_command_line
utility.execute()
File "C: \Users\admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\core\management\__init__.py", line 413, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\core\management\__init__.py", line 244, in fetch_command
settings.INSTALLED_APPS
File "C:\Users \admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\conf\__init__.py", line 82, in __getattr__
self._setup(name)
File "C:\Users\admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\conf\__init__.py", line 69, in _setup
self._wrapped = Settings(settings_module)
File "C :\Users\admin\AppData\Local\Programs\Python\Python39\lib\site-packages\django\conf\__init__.py", line 170, in __init__
mod = importlib.import_module(self.SETTINGS_MODULE)
File "C: \Users\admin\AppData\Local\Programs\Python\Python39\lib\importlib\__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1030 , in _gcd_import
File "", line 1007, in _find_and_load
File "", line 984, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'learning_log.settings'

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sand, 2021-06-24
@sand3001

KeyError: 'makemigretions'
Because makemigrations is not spelled the way you wrote it

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question