PJ Eby added the comment:
This area of the spec is different between 333 and precisely to clarify
this point, without technically changing conformance requirements. PEP 333 was
supposed to require the app to supply an argument, while PEP was changed
to encourage the server to allow
PJ Eby added the comment:
This is a misreading of the spec. The read() method is defined as taking
exactly one parameter. The server *should* support it being optional, but the
app invoking it without an argument is not compliant, and wsgiref.validate is
validating that the *app* performs
PJ Eby added the comment:
The fix for the server looks ok, but the validation and tests must not
be changed, since they void spec compatibility and aren't a bug fix
(and so must not be added to 2.7.) Indeed, if the validation library
*doesn't* fail on CRLF, then *that* would be a
PJ Eby added the comment:
You're right, it shouldn't send the headers until a non-empty string
occurs. I don't see any problem with treating it as a bug, and fixing it.
Your patch will also allow non-compliant behavior, though. It seems to me
it would be better to fix the logi
PJ Eby added the comment:
Please see this paragraph of the spec (my emphasis added):
(Note: the application must invoke the start_response() callable **before the
iterable yields its first body string**, so that the server can send the
headers before any body content. However, this invocation
PJ Eby added the comment:
Unfortunately, this is not quite true: the weird edge cases for that approach
are simply *different*, and harder to diagnose. ;-)
The approach here can only affect execution paths that would currently raise
ImportError; that one can break execution paths that are
PJ Eby added the comment:
The new patch will have weird results in the case of a parent module that
defines an attribute that's later replaced by an import, e.g. if
foo/__init__.py defines a variable 'bar' that's a proxy for the foo.bar module.
This is especially problema
Changes by PJ Eby :
--
title: NewInterface -> Remove -mno-cygwin from distutils
___
Python tracker
<http://bugs.python.org/issue12641>
___
___
Python-bugs-lis
Changes by PJ Eby :
Removed file: http://bugs.python.org/file31471/sa6.html
___
Python tracker
<http://bugs.python.org/issue12641>
___
___
Python-bugs-list mailin