Forums

Error running WSGI application

Error running WSGI application AttributeError: module 'cs337369_pythonanywhere_com_wsgi' has no attribute 'application'

imeages link

https://ibb.co/hdswT9p

https://ibb.co/4m9S2TJ

What's the problem?

You should define application object in your wsgi file, at the bottom of the file there should be something like:

# serve django via WSGI
from django.core.wsgi import get_wsgi_application
application = get_wsgi_application()

@pafk It became like this. In my settings.py intalled app, I erased the graphene-djanggo

Error running WSGI application ModuleNotFoundError: No module named 'graphene_django'

I'm not sure if I understand you correctly, module not found errors are usually related to installing the package for wrong Python version or outside of the venv that is used for the web app. Make sure you've installed the module for the same Python that runs your app.

It is about 3.7.6ver and 3.7.6ver difference. I'm a beginner. I've searched a lot, but I don't know the answer.

What version difference? Those are the same. Modules not being installed have nothing to do with the particular point version of Python. You're getting that error because the module is not installed into the virtualenv/python version that you are using to run your code. pip installs into Python 2.7, pip3.6 installs into Python 3.6 etc.

it's solved Thank you pafk and glenn