Monday, May 25, 2015

Im stuck with my WSGI FIle on pythonanywhere.com

939 :Traceback (most recent call last):  2015-05-25 18:45:19,939 :  File "/bin/user_wsgi_wrapper.py", line 130, in __call__  2015-05-25 18:45:19,939 :    self.error_log_file.logger.exception("Error running WSGI application")  2015-05-25 18:45:19,939 :  File "/usr/lib/python2.7/logging/__init__.py", line 1185, in exception  2015-05-25 18:45:19,940 :    self.error(msg, *args, **kwargs)  2015-05-25 18:45:19,940 :  File "/usr/lib/python2.7/logging/__init__.py", line 1178, in error  2015-05-25 18:45:19,940 :    self._log(ERROR, msg, args, **kwargs)  2015-05-25 18:45:19,940 :  File "/usr/lib/python2.7/logging/__init__.py", line 1270, in _log  2015-05-25 18:45:19,940 :    record = self.makeRecord(self.name, level, fn, lno, msg, args, exc_info, func, extra)  2015-05-25 18:45:19,940 :  File "/usr/lib/python2.7/logging/__init__.py", line 1244, in makeRecord  2015-05-25 18:45:19,941 :    rv = LogRecord(name, level, fn, lno, msg, args, exc_info, func)  2015-05-25 18:45:19,941 :  File "/usr/lib/python2.7/logging/__init__.py", line 284, in __init__  2015-05-25 18:45:19,941 :    self.threadName = threading.current_thread().name  2015-05-25 18:45:19,941 :  File "/usr/lib/python2.7/threading.py", line 1160, in currentThread  2015-05-25 18:45:19,941 :    return _active[_get_ident()]  2015-05-25 18:45:19,941 :  File "/bin/user_wsgi_wrapper.py", line 122, in __call__  2015-05-25 18:45:19,941 :    app_iterator = self.app(environ, start_response)  2015-05-25 18:45:19,941 :  File "/home/pycharm/.virtualenvs/django17/local/lib/python2.7/site-packages/django/core/handlers/wsgi.py", line 168, in __call__  2015-05-25 18:45:19,942 :    self.load_middleware()  2015-05-25 18:45:19,942 :  File "/home/pycharm/.virtualenvs/django17/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 44, in load_middleware  2015-05-25 18:45:19,942 :    mw_class = import_string(middleware_path)  2015-05-25 18:45:19,942 :  File "/home/pycharm/.virtualenvs/django17/local/lib/python2.7/site-packages/django/utils/module_loading.py", line 26, in import_string  2015-05-25 18:45:19,943 :    module = import_module(module_path)  2015-05-25 18:45:19,943 :  File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module  2015-05-25 18:45:19,943 :    __import__(name)  2015-05-25 18:45:19,943 :ImportError: No module named security



heres the code:


import os  import sys    # assuming your django settings file is at '/home/MYUSERNAME/MYSITE/settings.py'  path = '/home/pycharm/work'  if path not in sys.path:      sys.path.append(path)    os.environ['DJANGO_SETTINGS_MODULE'] = 'work.settings'  from django.core.wsgi import get_wsgi_application  application = get_wsgi_application()

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAAmfpZ18K2K%2BzDPAFEu38ZRXweheJr8Z5YWmcc4ctLpgHx1O%3Dg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment