A RetroSearch Logo

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

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2000-October/010149.html below:

[Python-Dev] sys.__stdout__

[Python-Dev] sys.__stdout__ [Python-Dev] sys.__stdout__Guido van Rossum guido@python.org
Wed, 25 Oct 2000 23:02:11 -0500
> So what _is_ it intended for?

Example: IDLE redirects sys.stderr so that it gets displayed in the
Python Shell window with a different text color.  But occasionally I
need to debug IDLE and the bug is in the text drawing.  Then it's nice
if I can write to __stderr__, which goes to the console.

Or suppose I'm in a regular interactive session and I've managed to
screw myself by assigning a bogus file object to sys.stdout (it
happens :-).  If I know that, I can type sys.stdout = sys.__stdout__
at the >>> prompt and save myself -- so I don't have to restart the
session and perhaps lose valuable data.

--Guido van Rossum (home page: http://www.python.org/~guido/)



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