Berker Peksag <berker.pek...@gmail.com> added the comment:

Please revert 360e1e4c519cfc139de707bcdd1e6c871eec79ee. It's not a good example 
to put into the documentation.

It uses different naming convention. It would only confuse users relatively new 
to the wsgiref module and WSGI protocol.

FileWrapper was supposed to support __getitem__ and __iter__ protocols for 
compatibility with older Python versions, but its __getiem__ implementation is 
buggy and is already deprecated. It has no use case in modern Python code.

It has zero exception handling and will return a cryptic traceback if mimetype 
cannot detect type of the file.

The examples in the wsgiref documentation already cover most of the cases. 
There is no need to add more similar ones.

----------
nosy: +berker.peksag

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue36345>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to