pexpect can't pass input over 1024 chars?
Your problem seems to be MacOS related, take a look at MacOSX 10.6.7 cuts off stdin at 1024 chars.
It basically says that 1024 is your tty buffer limit.
I'm not an expert on Mac OS, but maybe others can give you more informations about this.