Forums

ModuleNotFoundError: No module named 'distribution.settings'

There was an error loading your PythonAnywhere-hosted site. There may be a bug in your code.

Error code: Unhandled Exception

Traceback Log

ModuleNotFoundError: No module named 'distribution.settings' File "/var/www/www_breakfreenomad_com_wsgi.py", line 28, in <module> application = get_wsgi_application()

wsgi.py

> import os import sys
> #
> ## assuming your django settings file is at '/home/BreakFreeNomad/mysite/mysite/settings.py'
> ## and your manage.py is is at '/home/BreakFreeNomad/mysite/manage.py' path = '/home/BreakFreeNomad/distribution' if path not in sys.path:
>     sys.path.append(path)
> # os.environ['DJANGO_SETTINGS_MODULE'] = 'distribution.settings'
> #
>  ## then: from django.core.wsgi import get_wsgi_application application = get_wsgi_application()

Location to Settings.py

/home/BreakFreeNomad/distribution/src/blog

It seems like everything is commented out? You should uncomment the relevant code.

same problem

Make sure that you have installed the module that you're trying to import into the version of Python or virtualenv that you're trying to run the code in.