Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-18 Thread Phillip J. Eby

At 09:30 AM 11/18/2008 +1100, Graham Dumpleton wrote:

I would be for (1) errata or amendment as reality is that there is
probably no WSGI implementation that disallows an argument to
readline() given that certain Python code such as cgi.FieldStorage
wouldn't work otherwise.


Please note that that was a change in Python 2.5; older Pythons 
(including Jython until very recently) would not have needed a 
readline() argument, and so are less likely to have been tested that way.


___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-18 Thread Alan Kennedy
[Graham]
> I would be for (1) errata or amendment as reality is that there is
> probably no WSGI implementation that disallows an argument to
> readline() given that certain Python code such as cgi.FieldStorage
> wouldn't work otherwise.
>
> For such a clarification on existing practice, I see no point in
> having to change wsgi.version in environ as it would just cause
> confusion.

+1

[Graham]
> I would also like to see other changes to WSGI specification but now
> is not the time, let us at least though get this obvious issue with
> API dealt with. After that we can then perhaps have a discussion of
> future of WSGI specification and whether there really is any interest
> in future versions with more significant changes.

+1

Alan.
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Graham Dumpleton
2008/11/18 Tres Seaver <[EMAIL PROTECTED]>:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> Manlio Perillo wrote:
>> Phillip J. Eby ha scritto:
>>> At 08:49 PM 11/17/2008 +0100, Manlio Perillo wrote:
 Ian Bicking ha scritto:
> [...]
> We need to propose a change to the WSGI specification.  I propose, in
> "Input and Error Streams"
> (http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we
> change it to have "readline(hint)" and expand Note 3 to include
> readline as well as readlines, removing Note 2.  Also I suppose some
> sort of change note in the specification?
> Does this sound like a sufficient change to the spec, and are there
> any objections to the change?
 Fine for me, but of course we need to do this as:
 1) Errata to WSGI 1.0
 or
 2) WSGI 1.1
 or
 3) WSGI 2.0

 You can't just modify the current WSGI 1.0 spec.

 I'm for 2), with the other clarifications about WSGI we have discussed
 in the past.
>>> I'm more inclined towards #1.
>>
>> I'm not sure, since it is an API change; of course if there was an error
>> in the API this should be an errata, but there is a rationale behind the
>> current API.
>>
>> I'm fine, however, with an amendment.
>
> Isn't the rationale completely defeated by the equivalent, relaxed form
> for 'readlines' (note #3).  That was why I voted +1:  I couldn't see
> that relaxing 'readline' to match 'readlines' would make life any harder
> on server implementers.

I would be for (1) errata or amendment as reality is that there is
probably no WSGI implementation that disallows an argument to
readline() given that certain Python code such as cgi.FieldStorage
wouldn't work otherwise.

For such a clarification on existing practice, I see no point in
having to change wsgi.version in environ as it would just cause
confusion.

I would also like to see other changes to WSGI specification but now
is not the time, let us at least though get this obvious issue with
API dealt with. After that we can then perhaps have a discussion of
future of WSGI specification and whether there really is any interest
in future versions with more significant changes. Although, personally
I will not be holding my breath for that to happen. :-)

Graham
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Manlio Perillo wrote:
> Phillip J. Eby ha scritto:
>> At 08:49 PM 11/17/2008 +0100, Manlio Perillo wrote:
>>> Ian Bicking ha scritto:
 [...]
 We need to propose a change to the WSGI specification.  I propose, in 
 "Input and Error Streams" 
 (http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
 change it to have "readline(hint)" and expand Note 3 to include 
 readline as well as readlines, removing Note 2.  Also I suppose some 
 sort of change note in the specification?
 Does this sound like a sufficient change to the spec, and are there 
 any objections to the change?
>>> Fine for me, but of course we need to do this as:
>>> 1) Errata to WSGI 1.0
>>> or
>>> 2) WSGI 1.1
>>> or
>>> 3) WSGI 2.0
>>>
>>> You can't just modify the current WSGI 1.0 spec.
>>>
>>> I'm for 2), with the other clarifications about WSGI we have discussed 
>>> in the past.
>> I'm more inclined towards #1.  
> 
> I'm not sure, since it is an API change; of course if there was an error 
> in the API this should be an errata, but there is a rationale behind the 
> current API.
> 
> I'm fine, however, with an amendment.

Isn't the rationale completely defeated by the equivalent, relaxed form
for 'readlines' (note #3).  That was why I voted +1:  I couldn't see
that relaxing 'readline' to match 'readlines' would make life any harder
on server implementers.


Tres.
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJIePC+gerLs4ltQ4RAnsrAKCflurxZqxfJvjgX2YeU9XlXFDvPgCfQRcn
rHK7/cvRh9zm5x8PyTq3ZLE=
=c8v8
-END PGP SIGNATURE-

___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Manlio Perillo

Ian Bicking ha scritto:

[...]

Fine for me, but of course we need to do this as:
1) Errata to WSGI 1.0
or
2) WSGI 1.1
or
3) WSGI 2.0

You can't just modify the current WSGI 1.0 spec.

I'm for 2), with the other clarifications about WSGI we have discussed 
in the past.


I'm for 1.  What other clarifications were you thinking of?



Here is a list of messages I have posted in the past.

- start_response and error checking
  25 September 2007
  http://mail.python.org/pipermail/web-sig/2007-September/002771.html
- hop-by-hop headers handling
  1 October 2007
  http://mail.python.org/pipermail/web-sig/2007-October/002775.html
- HTTP_CONTENT_TYPE and HTTP_CONTENT_LENGTH
  12 December 2007
  http://mail.python.org/pipermail/web-sig/2007-December/003014.html
- a possible error in the WSGI spec
  20 December 2007
  http://mail.python.org/pipermail/web-sig/2007-December/003064.html
- calling start_response and the write from a separate thread
  27 December 2007
  http://mail.python.org/pipermail/web-sig/2007-December/003104.html
- WSGI and PEP 325
  20 May 2008
  http://mail.python.org/pipermail/web-sig/2008-May/003438.html


I'm rather sure there were other threads about clarifications of WSGI 1.0.

One of these was about if a WSGI gateway is allowed to skip the 
generation of the request body (assuming the WSGI applications returns a 
generator) if this is not required (the client cached copy of the 
request entity is up to date and the server is going to return 304 Not 
Modified)




Regards   Manlio Perillo
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Manlio Perillo

Phillip J. Eby ha scritto:

At 08:49 PM 11/17/2008 +0100, Manlio Perillo wrote:

Ian Bicking ha scritto:

[...]
We need to propose a change to the WSGI specification.  I propose, in 
"Input and Error Streams" 
(http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
change it to have "readline(hint)" and expand Note 3 to include 
readline as well as readlines, removing Note 2.  Also I suppose some 
sort of change note in the specification?
Does this sound like a sufficient change to the spec, and are there 
any objections to the change?


Fine for me, but of course we need to do this as:
1) Errata to WSGI 1.0
or
2) WSGI 1.1
or
3) WSGI 2.0

You can't just modify the current WSGI 1.0 spec.

I'm for 2), with the other clarifications about WSGI we have discussed 
in the past.


I'm more inclined towards #1.  


I'm not sure, since it is an API change; of course if there was an error 
in the API this should be an errata, but there is a rationale behind the 
current API.


I'm fine, however, with an amendment.


> [...]


Regards   Manlio Perillo
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Robert Brewer
Ian Bicking wrote:
> Manlio Perillo wrote:
> > Ian Bicking ha scritto:
> >> [...]
> >> We need to propose a change to the WSGI specification.  I propose,
> in
> >> "Input and Error Streams"
> >> (http://www.python.org/dev/peps/pep-0333/#input-and-error-streams)
> we
> >> change it to have "readline(hint)" and expand Note 3 to include
> >> readline as well as readlines, removing Note 2.  Also I suppose
some
> >> sort of change note in the specification?
> >>
> >> Does this sound like a sufficient change to the spec, and are there
> >> any objections to the change?
> >>
> >
> > Fine for me, but of course we need to do this as:
> > 1) Errata to WSGI 1.0
> > or
> > 2) WSGI 1.1
> > or
> > 3) WSGI 2.0
> >
> > You can't just modify the current WSGI 1.0 spec.
> >
> > I'm for 2), with the other clarifications about WSGI we have
> discussed
> > in the past.
> 
> I'm for 1.  What other clarifications were you thinking of?

PLEASE don't ask, don't tell. Let's not complicate this change by
conflating it with others yet again.


Robert Brewer
[EMAIL PROTECTED]

___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Phillip J. Eby

At 08:49 PM 11/17/2008 +0100, Manlio Perillo wrote:

Ian Bicking ha scritto:

[...]
We need to propose a change to the WSGI specification.  I propose, 
in "Input and Error Streams" 
(http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) 
we change it to have "readline(hint)" and expand Note 3 to include 
readline as well as readlines, removing Note 2.  Also I suppose 
some sort of change note in the specification?
Does this sound like a sufficient change to the spec, and are there 
any objections to the change?


Fine for me, but of course we need to do this as:
1) Errata to WSGI 1.0
or
2) WSGI 1.1
or
3) WSGI 2.0

You can't just modify the current WSGI 1.0 spec.

I'm for 2), with the other clarifications about WSGI we have 
discussed in the past.


I'm more inclined towards #1.  But in any event we need to get 
clearer about how the amendment or erratum will be phrased.



___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Ian Bicking

Manlio Perillo wrote:

Ian Bicking ha scritto:

[...]
We need to propose a change to the WSGI specification.  I propose, in 
"Input and Error Streams" 
(http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
change it to have "readline(hint)" and expand Note 3 to include 
readline as well as readlines, removing Note 2.  Also I suppose some 
sort of change note in the specification?


Does this sound like a sufficient change to the spec, and are there 
any objections to the change?




Fine for me, but of course we need to do this as:
1) Errata to WSGI 1.0
or
2) WSGI 1.1
or
3) WSGI 2.0

You can't just modify the current WSGI 1.0 spec.

I'm for 2), with the other clarifications about WSGI we have discussed 
in the past.


I'm for 1.  What other clarifications were you thinking of?


--
Ian Bicking : [EMAIL PROTECTED] : http://blog.ianbicking.org
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Manlio Perillo

Ian Bicking ha scritto:

[...]
We need to propose a change to the WSGI specification.  I propose, in 
"Input and Error Streams" 
(http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
change it to have "readline(hint)" and expand Note 3 to include readline 
as well as readlines, removing Note 2.  Also I suppose some sort of 
change note in the specification?


Does this sound like a sufficient change to the spec, and are there any 
objections to the change?




Fine for me, but of course we need to do this as:
1) Errata to WSGI 1.0
or
2) WSGI 1.1
or
3) WSGI 2.0

You can't just modify the current WSGI 1.0 spec.

I'm for 2), with the other clarifications about WSGI we have discussed 
in the past.




Regards  Manlio Perillo
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Ian Bicking wrote:
> Mark Ramm wrote:
>> On Mon, Nov 17, 2008 at 12:55 PM, Andrew Clover <[EMAIL PROTECTED]> wrote:
>>> Ian Bicking wrote:
>>>
 To resolve this, let's just not pass it over this time?
>> Totally agreed.
>>
>> What exactly needs to happen next?
> 
> We need to propose a change to the WSGI specification.  I propose, in 
> "Input and Error Streams" 
> (http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
> change it to have "readline(hint)" and expand Note 3 to include readline 
> as well as readlines, removing Note 2.  Also I suppose some sort of 
> change note in the specification?
>
> Does this sound like a sufficient change to the spec, and are there any 
> objections to the change?

+1 from me.


Tres.
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD4DBQFJIb90+gerLs4ltQ4RAt/5AJdkn2ObmgAN2SU3dd8E4KNXolz5AJwIgOJP
D9ZKBwF5jUunMrlQXaDbkA==
=hUNu
-END PGP SIGNATURE-

___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Ian Bicking

Mark Ramm wrote:

On Mon, Nov 17, 2008 at 12:55 PM, Andrew Clover <[EMAIL PROTECTED]> wrote:

Ian Bicking wrote:


To resolve this, let's just not pass it over this time?


Totally agreed.

What exactly needs to happen next?


We need to propose a change to the WSGI specification.  I propose, in 
"Input and Error Streams" 
(http://www.python.org/dev/peps/pep-0333/#input-and-error-streams) we 
change it to have "readline(hint)" and expand Note 3 to include readline 
as well as readlines, removing Note 2.  Also I suppose some sort of 
change note in the specification?


Does this sound like a sufficient change to the spec, and are there any 
objections to the change?


--
Ian Bicking : [EMAIL PROTECTED] : http://blog.ianbicking.org
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Mark Ramm
On Mon, Nov 17, 2008 at 12:55 PM, Andrew Clover <[EMAIL PROTECTED]> wrote:
> Ian Bicking wrote:
>
>> To resolve this, let's just not pass it over this time?

Totally agreed.

What exactly needs to happen next?
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-17 Thread Andrew Clover

Ian Bicking wrote:


To resolve this, let's just not pass it over this time?


+1

--
And Clover
mailto:[EMAIL PROTECTED]
http://www.doxdesk.com/
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-16 Thread Robert Brewer
+1

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:web-sig-
> [EMAIL PROTECTED] On Behalf Of Ian Bicking
> Sent: Sunday, November 16, 2008 10:06 AM
> To: Graham Dumpleton
> Cc: Web SIG
> Subject: Re: [Web-SIG] Revising environ['wsgi.input'].readline in the
> WSGI specification
> 
> Graham Dumpleton wrote:
> > 2008/11/16 Ian Bicking <[EMAIL PROTECTED]>:
> >> We need to make a revision to the WSGI spec to say that
> >> environ['wsgi.input'].readline takes an optional size argument.  It
> always
> >> does in practice (except in wsgiref.validate.validator, rendering
> that
> >> validator useless), and is required to in practice, because
everyone
> uses
> >> cgi.FieldStorage, and it passes in that argument.
> >
> > This has been brought up numerous times before. There are other
> things
> > about wsgi.input that really need to be changed as well to make it
> > more useful. When I have pushed for revised specification before I
> > could never get enough interest in it from the people that most
would
> > perceive are the ones who oversee the PEP.
> 
> Yes, this has been passed over before.  To resolve this, let's just
not
> pass it over this time?  This is a relatively small change to the WSGI
> spec, because it represents standard practice -- this change is simply
> getting the spec in line with implementations.
> 
> --
> Ian Bicking : [EMAIL PROTECTED] : http://blog.ianbicking.org
> ___
> Web-SIG mailing list
> Web-SIG@python.org
> Web SIG: http://www.python.org/sigs/web-sig
> Unsubscribe: http://mail.python.org/mailman/options/web-
> sig/fumanchu%40aminus.org
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-16 Thread Ian Bicking

Graham Dumpleton wrote:

2008/11/16 Ian Bicking <[EMAIL PROTECTED]>:

We need to make a revision to the WSGI spec to say that
environ['wsgi.input'].readline takes an optional size argument.  It always
does in practice (except in wsgiref.validate.validator, rendering that
validator useless), and is required to in practice, because everyone uses
cgi.FieldStorage, and it passes in that argument.


This has been brought up numerous times before. There are other things
about wsgi.input that really need to be changed as well to make it
more useful. When I have pushed for revised specification before I
could never get enough interest in it from the people that most would
perceive are the ones who oversee the PEP.


Yes, this has been passed over before.  To resolve this, let's just not 
pass it over this time?  This is a relatively small change to the WSGI 
spec, because it represents standard practice -- this change is simply 
getting the spec in line with implementations.


--
Ian Bicking : [EMAIL PROTECTED] : http://blog.ianbicking.org
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com


Re: [Web-SIG] Revising environ['wsgi.input'].readline in the WSGI specification

2008-11-15 Thread Graham Dumpleton
2008/11/16 Ian Bicking <[EMAIL PROTECTED]>:
> We need to make a revision to the WSGI spec to say that
> environ['wsgi.input'].readline takes an optional size argument.  It always
> does in practice (except in wsgiref.validate.validator, rendering that
> validator useless), and is required to in practice, because everyone uses
> cgi.FieldStorage, and it passes in that argument.

This has been brought up numerous times before. There are other things
about wsgi.input that really need to be changed as well to make it
more useful. When I have pushed for revised specification before I
could never get enough interest in it from the people that most would
perceive are the ones who oversee the PEP.

Graham
___
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com