web/ldt/core/handlers/modpython.py
author wakimd
Sun, 14 Nov 2010 20:25:22 +0100
changeset 1 3a30d255c235
permissions -rw-r--r--
First version of API with tests
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     1
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     2
def handler(req):
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     3
    activate_this = req.get_options().get("virtualenv.activate_path")
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     4
    execfile(activate_this, dict(__file__=activate_this))    
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     5
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     6
    import django.core.handlers.modpython
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     7
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     8
    return django.core.handlers.modpython.handler(req)