[Web-SIG] Why is response_headers a list instead of a dict?
Clark C. Evans
cce at clarkevans.com
Tue Dec 27 21:38:21 CET 2005
Thank you for humoring the discussion (I realize it was covered in the
PEP). I've since found a solution which covers my requirements of
making header access easier in ``environ`` and ``response_headers`` yet
keeping to the spirt of WSGI (but I'll let you be the final judge). It
involves turning header "definitions" into objects:
Anyway, the final result is actually much better than I expected, it is
far more modular/extendable than the extensions/wrappers I had started
to implement earlier. So, I must thank you for sticking to your policy;
despite my complaints earlier, it seems to be a very wise choice.
P.S. The work above is usable; but incomplete in a few minor ways. It
will soon be getting concrete (rather than generic) implementations for
the more complicated HTTP headers that I work with: Content-Disposition,
Cache-Control, Set-Cookie, etc. Suggestions, of course, are very
welcome. At this time the module has no dependencies, and so far the
rest of Paste does not depend upon it, however, if Ian agrees, much of
paste could be re-configured to use this module (especially the
fileapp.py module which is one of the motivators).
More information about the Web-SIG