Hi
You are probably typing this within IDLE. Try it after starting python in a shell like DOS or Bash. Should work then (works for me, and I also get the AttributeError in IDLE.
Thanks Caleb
On Tue, 07 Dec 2004 21:15:51 GMT, It's me <[EMAIL PROTECTED]> wrote:
Why do I get an "AttributeError: read" message when I do:
import sys r=sys.stdin.read()
??
I've tried:
r=sys.stdin.read(80) r=sys.stdin.read(1)
same error message.
I couldn't find any reference to this function in my Python book (they have
the stdout but not in).
Some sample code I saw uses this function in the same manner I am and so I
am assuming this is the correct syntax?
Or is this a bug in Python 2.4?
-- It's me
-- http://mail.python.org/mailman/listinfo/python-list