A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2002-March/021114.html below:

[Python-Dev] Next version of PEP278 - universal newline support

[Python-Dev] Next version of PEP278 - universal newline support - available [Python-Dev] Next version of PEP278 - universal newline support - availableAahz aahz@pythoncraft.com
Thu, 14 Mar 2002 11:25:28 -0500
On Thu, Mar 14, 2002, Guido van Rossum wrote:
>
> I wonder if it would make sense to put a warning when people use
> f.read(n) on a file opened in text mode?  I think f.read(n) is an
> almost sure sign that they're seeing the file as binary data.
> However, f.read() or f.read(-1) is used to slurp in text as well, so
> should not trigger the warning.
> 
> Opinions?

+1

Warnings for something we know to be a problem are "always" good.  The
only worry is CGI scripts, but even then warnings go to stderr, right?
-- 
Aahz (aahz@pythoncraft.com)           <*>         http://www.pythoncraft.com/

The best way to get information on Usenet is not to ask a question, but
to post the wrong information.  --Aahz



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4