Re: lighttpd SCGI + Quixote, Location / ?

David Binger <[email protected]>
Newsgroups gmane.comp.web.quixote.user
Message-ID <[email protected]>
In my previous response on this thread, I suggested that
a patch should be made to _q_traverse() when I meant to
say try_publish().

Here is the version of Publisher.try_publish() that I think
might be helpful:

     def try_publish(self, request):
         """(request : HTTPRequest) -> object

         The master method that does all the work for a single request.
         Exceptions are handled by the caller.
         """
         self.start_request()
         path = request.get_environ('PATH_INFO', '')
         # from pprint import pformat; print pformat(request.environ)
         if path[:1] != '/':
             return redirect(
                 request.get_environ('SCRIPT_NAME', '') + '/' + path,
                 permanent=True)
         components = path[1:].split('/')
         output = self.root_directory._q_traverse(components)
         # The callable ran OK, commit any changes to the session
         self.finish_successful_request()
         return output

Also, and perhaps more useful here, the scgi_server.py program should
probably be started with --script-name=/scgi-test so that it will
patch up the incorrect values in the environment that comes from
lighttpd.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.