[Python-Dev] Re: A warning switch?

Mark Hammond mhammond@skippinet.com.au
Thu, 2 Mar 2000 10:09:23 +1100

> > Can we then please have an interface to the "give warning" call (in
> > stead of a simple fprintf)? On the mac (and possibly also in
> > PythonWin) it's probably better to pop up a dialog (possibly with a
> > "don't show again" button) than do a printf which may get lost.
> Sure.  All you have to do is code it (or get someone else to code it).

How about just having either a "sys.warning" function, or maybe even a
sys.stdwarn stream?  Then a simple C API to call this, and we are done :-)
sys.stdwarn sounds OK - it just defaults to sys.stdout, so the Mac and
Pythonwin etc should "just work" by sending the output wherever sys.stdout
goes today...