So I am about to start working on a project with Python Django (never worked with these before). However, before starting I want to run the application.
My manager gave me the files on which I should be working and there is the manage.py file already created. Now I have installed Python, pip and django and am trying to run this with the command python manage.py runserver
And I get this long error which I am not sure what is all about considering that this whole project is already working on the computer of my manager and is even uploaded to a host.
Watching for file changes with StatReloader
Exception in thread django-main-thread:
Traceback (most recent call last):
File "C:\Program Files\Python310\lib\threading.py", line 1009, in _bootstrap_inner
self.run()
File "C:\Program Files\Python310\lib\threading.py", line 946, in run
self._target(*self._args, **self._kwargs)
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\utils\autoreload.py", line 64, in wrapper
fn(*args, **kwargs)
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\core\management\commands\runserver.py", line 115, in inner_run
autoreload.raise_last_exception()
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\utils\autoreload.py", line 87, in raise_last_exception
raise _exception[1]
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\core\management\__init__.py", line 381, in execute
autoreload.check_errors(django.setup)()
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\utils\autoreload.py", line 64, in wrapper
fn(*args, **kwargs)
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\apps\registry.py", line 91, in populate
app_config = AppConfig.create(entry)
File "C:\Users\Admin\AppData\Roaming\Python\Python310\site-packages\django\apps\config.py", line 223, in create
import_module(entry)
File "C:\Program Files\Python310\lib\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 'crispy_forms'
Now I am not sure what any of this is considering that I haven't started learning or messing with the code yet. But it's particularly strange to me considering that the code is supposed to be working.
Is this error maybe not related to code or related to something else? Any ideas and tips on what this is and how to fix it would be extremely appreciated!
CodePudding user response:
