[Tutor] Stdin email question

Magnus Lyckå magnus@thinkware.se
Sun May 18 03:36:37 2003


At 01:56 2003-05-18 -0400, Kirk Bailey wrote:
>Go read the rfc822 module.
>SOMEPLACE in there is a sys.stdin.readlines() statement, and it dumps the 
>data into a named variable. NAME YOUR DESTINATION VARIABLE THAT.
>With any luck you can not invoke something that will read the stdin, which 
>woud of course result in a output of '' (null string) as there is no input 
>pending to read! and THAT would stick '' into all the functions looking at 
>that variable.

Don't do this.

Relying on the internals of another module means that
you violate Parnas' Principle, one of the most important
principles in programming. (Search the web for more info.)


--
Magnus Lycka (It's really Lyckå), magnus@thinkware.se
Thinkware AB, Sweden, www.thinkware.se
I code Python ~ The shortest path from thought to working program