[Web-SIG] WSGI Utils & SCGI/Quixote.
Titus Brown
titus at caltech.edu
Wed Dec 1 01:04:50 CET 2004
-> > My experience highlights an issue that needs to be dealt with by any
-> > WSGI server code. Several app frameworks -- Quixote Webware, and Zope,
-> > for example -- expect to be handed control of an entire URL tree.
->
-> I handled this control issue using the following code:
->
-> # Magic dictionary for WSGIServer.
->
-> class MagicDict:
-> def __init__(self, handler):
-> self.handler = handler
-> def has_key(self, name):
-> return 1
-> def __getitem__(self, name):
-> return self.handler
->
-> When such an object is passed to WSGIServer, the specified handler always gets
-> control, although it'd surely be preferable for so-called "WSGI middleware"
-> to manage the URL space.
this still has the problem that env["SCRIPT_NAME"] and env["PATH_INFO"]
aren't munged appropriately, no? I know this would be a problem with
Quixote, not sure about the rest.
--titus
More information about the Web-SIG
mailing list