Forums

ImportError: No module named 'mysite'

Hi. I deployed my app and there is some error which says :

Error running WSGI application
ImportError: No module named 'mysite'
File "/var/www/golshan_pythonanywhere_com_wsgi.py", line 12, in <module>
application = StaticFilesHandler(get_wsgi_application())

 File "/home/Golshan/my-first-blog/myenv/lib/python3.4/site-packages/django/core/wsgi.py", line 14, in get_wsgi_application
  django.setup()

  File "/home/Golshan/my-first-blog/myenv/lib/python3.4/site-packages/django/__init__.py", line 17, in setup
 configure_logging(settings.LOGGING_CONFIG, settings.LOGGING)

File "/home/Golshan/my-first-blog/myenv/lib/python3.4/site-packages/django/conf/__init__.py", line 48, in     self._setup(name)

 File "/home/Golshan/my-first-blog/myenv/lib/python3.4/site-packages/django/conf/__init__.py", line 44, in _setup
self._wrapped = Settings(settings_module)
File "/home/Golshan/my-first-blog/myenv/lib/python3.4/site-packages/django/conf/__init__.py", line 92, in __init__
 mod = importlib.import_module(self.SETTINGS_MODULE

I dont know where is "mysite" ?!!! I dont have anything with this name in my codes or pathes

Take a look at your wsgi.py file.

I have the same problem

Here is the wsgi.py file , I dont know whats wrong with it !

import os

from django.core.wsgi import get_wsgi_application

os.environ.setdefault("DJANGO_SETTINGS_MODULE", "BallBearingProject.settings")

application = get_wsgi_application()

are you sure you are getting the same error? What is the full error traceback?

not exactly the same, i asked it in new post :)