我正在尝试为我喜欢的项目创建迁移。但是,我遇到了一个错误,无法谷歌的答案:它说:
`vincent@master-PC:/media/vincent/82944C77944C6FA9/Users/Ghost/Desktop/Python/PB/lesson 40/meeting_planner$ python3 manage.py makemigrations
Traceback (most recent call last):
File "/media/vincent/82944C77944C6FA9/Users/Ghost/Desktop/Python/PB/lesson 40/meeting_planner/manage.py", line 22, in <module>
main()
File "/media/vincent/82944C77944C6FA9/Users/Ghost/Desktop/Python/PB/lesson 40/meeting_planner/manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/home/vincent/.local/share/virtualenvs/lesson_40-49hQCJIK/lib/python3.10/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
utility.execute()
File "/home/vincent/.local/share/virtualenvs/lesson_40-49hQCJIK/lib/python3.10/site-packages/django/core/management/__init__.py", line 420, in execute
django.setup()
File "/home/vincent/.local/share/virtualenvs/lesson_40-49hQCJIK/lib/python3.10/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/home/vincent/.local/share/virtualenvs/lesson_40-49hQCJIK/lib/python3.10/site-packages/django/apps/registry.py", line 91, in populate
app_config = AppConfig.create(entry)
File "/home/vincent/.local/share/virtualenvs/lesson_40-49hQCJIK/lib/python3.10/site-packages/django/apps/config.py", line 193, in create
import_module(entry)
File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1004, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'django.contrib.cont enttypes'
P.S.我正在使用SQLite数据库
我确实在设置中正确定义了我的应用程序(检查了两次),尝试重新启动我的VScode和pipenv,但是没有成功。
1条答案
按热度按时间owfi6suc1#
应为