Berker Peksag added the comment:
Patch updated. If there's no objections, I'll commit this patch in the next
couple of days.
--
assignee: pje - berker.peksag
stage: patch review - commit review
Added file: http://bugs.python.org/file35814/issue5800_v3.diff
R. David Murray added the comment:
Since we don't need to avoid new language features, using the ternary would be
better than using the or. This is exactly the sort of situation the ternary
was introduced for: making sure the input really is None before applying the
default.
Otherwise the
Roundup Robot added the comment:
New changeset a91f0d4a2381 by Berker Peksag in branch 'default':
Issue #5800: headers parameter of wsgiref.headers.Headers is now optional.
http://hg.python.org/cpython/rev/a91f0d4a2381
--
nosy: +python-dev
___
Python
Berker Peksag added the comment:
Thanks for the patch and review.
--
resolution: - fixed
stage: commit review - resolved
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
Berker Peksag added the comment:
Here's a new patch with a whatsnew entry. David, could you review the patch?
--
nosy: +r.david.murray
Added file: http://bugs.python.org/file35787/issue5800_v2.diff
___
Python tracker rep...@bugs.python.org
Mark Lawrence added the comment:
This shouldn't be languishing, work has been committed against revision 86742
and there's another patch that apparently just needs a little tweak.
--
nosy: +BreamoreBoy
___
Python tracker rep...@bugs.python.org
Berker Peksag added the comment:
The patch is not committed yet.
$ ./python
Python 3.5.0a0 (default:979aaa08c067+, Jun 19 2014, 13:01:36)
[GCC 4.6.3] on linux
Type help, copyright, credits or license for more information.
from wsgiref.headers import Headers
h = Headers()
Traceback (most
Mark Lawrence added the comment:
Just for the record clicking on revision 86742 gives Specified revision
r86742 not found.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Éric Araujo mer...@netwok.org added the comment:
I think the doc should say something like “default value is an empty list”, for
maximum clarity.
--
versions: +Python 3.3 -Python 3.2
___
Python tracker rep...@bugs.python.org
SilentGhost ghost@gmail.com added the comment:
Looks good to me.
Would you mind committing it then?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
SilentGhost ghost@gmail.com added the comment:
Here's the single-file patch against the revision.
--
Added file: http://bugs.python.org/file21016/issue5800.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
Changes by SilentGhost ghost@gmail.com:
Removed file: http://bugs.python.org/file19681/test_wsgiref.py.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Changes by SilentGhost ghost@gmail.com:
Removed file: http://bugs.python.org/file19797/headers.py.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Changes by SilentGhost ghost@gmail.com:
Removed file: http://bugs.python.org/file19804/wsgiref.rst.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Phillip J. Eby p...@telecommunity.com added the comment:
Looks good to me.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
___
Changes by SilentGhost ghost@gmail.com:
--
status: open - languishing
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
___
Éric Araujo mer...@netwok.org added the comment:
LGTM.
--
assignee: - pje
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
___
Changes by SilentGhost michael.mischurow+...@gmail.com:
Removed file: http://bugs.python.org/file19680/headers.py.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
SilentGhost michael.mischurow+...@gmail.com added the comment:
Re-submitting the patch for Lib/wsgiref/headers.py w/o the isinstance change
--
keywords: +patch
Added file: http://bugs.python.org/file19797/headers.py.diff
___
Python tracker
Changes by Dirkjan Ochtman dirk...@ochtman.nl:
--
keywords: +needs review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
___
SilentGhost michael.mischurow+...@gmail.com added the comment:
Here is the correction for the docs. I would love to see this making it into
3.2 release.
--
Added file: http://bugs.python.org/file19804/wsgiref.rst.diff
___
Python tracker
Ramiro Batista da Luz ramiro...@gmail.com added the comment:
I reviewed the patch.
- I applied all the patchs(3 files).
- Ran make and make html in the Doc directory.
- Ran the test_wsgiref.py
- Ran the python interpreter and typed the suggested code:
from wsgiref.headers import Headers
Phillip J. Eby p...@telecommunity.com added the comment:
Yes, please consider the type-isinstance part of the change rejected. I just
got done reverting a bunch of those in 3.2. Where WSGI specifies types, it
means type() is, not isinstance.
(The 3.x version of wsgiref does not need to be
SilentGhost michael.mischurow+...@gmail.com added the comment:
Do I have to resubmit the patch or can you use the existing one?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
SilentGhost michael.mischurow+...@gmail.com added the comment:
Correct and update patch + update test case
--
keywords: +patch
nosy: +SilentGhost
Added file: http://bugs.python.org/file19680/headers.py.diff
___
Python tracker rep...@bugs.python.org
SilentGhost michael.mischurow+...@gmail.com added the comment:
here is the updated test case
--
Added file: http://bugs.python.org/file19681/test_wsgiref.py.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
Changes by R. David Murray rdmur...@bitdance.com:
--
keywords: -patch
stage: unit test needed - patch review
versions: -Python 2.7
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Ramiro Batista da Luz ramiro...@gmail.com added the comment:
I applied the patches for wsgiref.headers and test_headers.py, ran the test
with runtests.sh test_headers.py and it passed.
I also tried the code in the description:
from wsgiref.headers import Headers
headers = Headers()
Éric Araujo mer...@netwok.org added the comment:
FTR, note that “svn diff file1 file2...” will give you one file for many edits.
It’s easier to review and apply.
Regarding the change, I don’t know if wsgiref 3.2 has to be compatible with
Python 2.1, which would exclude using the ternary
Pablo Torres Navarrete tn.pa...@gmail.com added the comment:
Patch attached. While I was at it, I also removed stupid whitespace and
generally made the module more PEP8-compliant.
--
nosy: +ptn
Added file: http://bugs.python.org/file14311/patch
___
Tarek Ziadé ziade.ta...@gmail.com added the comment:
I have added another issue for PEP 8 compliancy at #5801
--
versions: +Python 3.2 -Python 3.1
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
Pablo Torres Navarrete tn.pa...@gmail.com added the comment:
Added a pointer from #5801 to here.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
Changes by Daniel Diniz aja...@gmail.com:
--
keywords: +easy
stage: - test needed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5800
___
___
New submission from Tarek Ziadé ziade.ta...@gmail.com:
wsgiref.headers.Headers will let you manage a collection of HTTP
response headers, but the constructor forces you to provide a list:
from wsgiref.headers import Headers
headers = Headers([])
headers.add_header('Content-Type',
34 matches
Mail list logo