Re: WSGI2: write callable?
PJ Eby <pje-Wh6+Hckhi6HFNGf7iClzIwC/[email protected]> Fri, 26 Sep 2014 15:58:13 -0400
| Newsgroups | gmane.comp.python.web |
|---|---|
| Message-ID | <CALeMXf5h6zRbpppy70fPjrff+5FSLTrc_NHyra-eQoC2Ob7p6Q@mail.gmail.com> |
On Thu, Sep 25, 2014 at 11:32 PM, Robert Collins <[email protected]> wrote: > So I propose we drop the write callable, and include a queue based > implementation in the adapter for PEP-3333 code. If you're dropping write(), then you might as well drop start_response() altogether, and replace it with returning a (status, headers, body-iterator) tuple, as in wsgi_lite ( https://github.com/pjeby/wsgi_lite ) or as found in other languages' versions of WSGI. (start_response+write was only ever needed in order to support legacy apps, so other languages never bothered.) wsgi_lite has a couple of other protocol extensions, namely the 'wsgi_lite.closing' environment key, flagging callables' supported WSGI version (for transparent interop), and the argument binding protocol, but for the most part these are orthogonal to the calling schema. I would suggest, however, that the calling protocol be flagged in some way to allow easier interop. _______________________________________________ Web-SIG mailing list [email protected] Web SIG: http://www.python.org/sigs/web-sig Unsubscribe: https://mail.python.org/mailman/options/web-sig/gcpw-web-sig%40m.gmane.org