Jump to content

Recommended Posts

Posted

I am trying to set up a Django project. I followed the directions on http://www.heliohost.org/home/features/languages/python, but I am getting a 500 error on line 9.

 

My username is aboyce

The domain I am testing is http://www.klickfu.heliohost.org/klickfu/dispatch.wsgi/hello

 

I copied the dispatch.wsgi file directly from the instructions (with the appropriate mods for paths). Here is what I am using:

 

 

import os, sys 
sys.path.append("/home/aboyce/public_html/klickfu"); 
os.environ['DJANGO_SETTINGS_MODULE'] = 'settings' 
os.environ['PYTHON_EGG_CACHE'] = '/home/aboyce/.python_egg_cache' 
import django.core.handlers.wsgi 
_application = django.core.handlers.wsgi.WSGIHandler() 
def application(environ, start_response): 
    environ['PATH_INFO'] = environ['SCRIPT_NAME'] + environ['PATH_INFO'] 
    return _application(environ, start_response)

 

Permissions were set as per instructions.

 

The topics that concerned this were all handled a year ago. The links for Byron's djangotest.zip have goen away.

Any help would be appreciated.

Posted
Is your home directory home1 or home?

 

Here's the working zip:

 

http://byrondallas.heliohost.org/djangtest.zip

 

Make sure you edit dispatch.wsgi to match your site and chmode the egg chache to 777.

 

http://byrondallas.heliohost.org/djangotest/dispatch.wsgi

 

 

Thanks, I got it working. Turns out the problem was with both my dispatcher.wsgi and settinys.py files. Your samples helped a lot. You might want to put a link to the zip file on the Python & DJango page. Thanks again.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...