[Web-SIG] WSGI and start_response

Graham Dumpleton graham.dumpleton at gmail.com
Thu Apr 15 01:35:00 CEST 2010


On 15 April 2010 02:53, Manlio Perillo <manlio_perillo at libero.it> wrote:
> Dirkjan Ochtman ha scritto:
>> On Tue, Apr 13, 2010 at 14:46, Graham Dumpleton
>> <graham.dumpleton at gmail.com> wrote:
>>> The last attempt was to have WSGI 1.1 as clarifications and Python 3.X.
>>>
>>> And when I say 'last attempt', yes there have been people who have
>>> stepped up to try and get this to happen in the past. I think you
>>> would be the 3rd time, excluding me in general having tried to push it
>>> in the past and also given up.
>>>
>>> You really should perhaps look back through the archive of WEB-SIG
>>> posts on Google Groups to understand the history and how this always
>>> seems to just go around in circles. :-)
>>
>> I've been on Web-SIG for quite a while now, exactly to keep track of
>> these issues.
>>
>> Since there doesn't seem to be much traction, I figured it would be
>> time to just get a new PEP together. To limit the amount of work, I'd
>> go in the direction of having a single WSGI 2.0 PEP incorporating your
>> suggestions (maybe minus the number 3), everything required for Python
>> 3 (as outlined by your wiki page).
>>
>
> If you volunteer for this task, I have some suggestions:
>
> * target WSGI 1.1, not WSGI 2.0
> * take the original WSGI 1.0 spec text
> * start to integrate all changes documented by Graham
> * I would really like to have changes integrates as a series of diff,
>  using <del> and <ins> HTML elements.
>
>  Unfortunately docutils seems to not have support for this, but should
>  not be hard to implement. I can help.
> * You should keep a separate, unofficial document, with the rationale of
>  the changes.
>  You can just copy the content of Graham blog post, and reformatting
>  it, if this is ok for Graham
> * For each of the main changea, start a thread on this mailing list
>  asking for votation.
>  If, after 1 week, there is no vote against it, consider it approved
>
>
> If we are really going to approve WSGI 1.1, I have a request: remove the
> ``write`` callable.
> Rationale:
> * it was added in WSGI 1.0 only for compatibility
> * new code does not use it
> * this will force applications under development that still use the
>  ``write`` callable to be fixed. See work on Mercurial
> * it is very easy for current implementations to support both WSGI 1.0
>  and WSGI 1.1
> * legacy application will continue to work
> * removing of the ``write`` callable will make middlewares more easy to
>  write

This is in part why an attempt to come up with a new WSGI 1.X
specification, even one that covers just the obvious and justified
changes because of actual problems, keeps failing. That is, parties
with vested interests or a desire for their little pet change to be
made because it helps them, keep poking their heads up and disrupting
the process.

Given how long this has taken, all that should happen at this point is
a codification of what wsgiref implements for Python 3.X along with
readline() argument change and obvious other clarifications where
actual use shows the original WSGI specification was wrong or where it
wasn't practical.

If that isn't done, we will be here in another year still arguing
about whether some aspect of the specification should be changed or
removed based on some individuals perceived need.

Such a significant change as removing the requirement for write()
should also not be done within a minor version of the WSGI
specification because anything that works with WSGI 1.0 should still
work with WSGI 1.1 and vice versa. On that basis it can't really be
entertained until WSGI 2.0 where incompatible changes would be
allowed.

Graham


More information about the Web-SIG mailing list