Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #38170

Re: autoflush on/off

Path csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!ecngs!feeder2.ecngs.de!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.005
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'sys.stderr': 0.09; 'terry': 0.09; 'emanuele': 0.16; 'idle.': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'header:User- Agent:1': 0.26; 'looks': 0.26; 'header:X-Complaints-To:1': 0.28; 'subject:/': 0.28; 'fine': 0.28; 'writes:': 0.29; 'to:addr:python- list': 0.33; "can't": 0.34; 'received:org': 0.36; 'should': 0.36; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'header:Received:5': 0.40; 'subject:off': 0.65; 'quando': 0.84
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Lele Gaifax <lele@metapensiero.it>
Subject Re: autoflush on/off
Date Tue, 05 Feb 2013 08:40:58 +0100
Organization Nautilus Entertainments
References <CAOuJsMmQ55vjG_TYU2iPNHeA=b-kGX+cWa2xFDXp4j6WfQAp3Q@mail.gmail.com> <kep8as$c12$1@ger.gmane.org> <CAOuJsM=Xv-VH_Jr0jh-1ysnbFAAn8WL+dNd+23Qh+6yZXgO-cQ@mail.gmail.com> <keq9nk$qv2$1@ger.gmane.org>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 8bit
X-Gmane-NNTP-Posting-Host 78.134.24.218
User-Agent Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)
Cancel-Lock sha1:cIz8VtRxbyyQ0Hwq0yQdVwerm98=
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.1355.1360050070.2939.python-list@python.org> (permalink)
Lines 14
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1360050070 news.xs4all.nl 6842 [2001:888:2000:d::a6]:44095
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:38170

Show key headers only | View raw


Terry Reedy <tjreedy@udel.edu> writes:

> It looks like you should perhaps just forget about reopening and just
> use sys.stdout.flush(). This works fine even on IDLE.

As an alternative, can't you just use sys.stderr for printing such
feedback? sys.stderr is unbuffered by default...

ciao, lele.
-- 
nickname: Lele Gaifax | Quando vivrò di quello che ho pensato ieri
real: Emanuele Gaifas | comincerò ad aver paura di chi mi copia.
lele@metapensiero.it  |                 -- Fortunato Depero, 1929.

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: autoflush on/off Lele Gaifax <lele@metapensiero.it> - 2013-02-05 08:40 +0100

csiph-web