.pyc from stdin?

Shay Telfer shaypython at earthyself.com
Wed Oct 7 15:54:58 CEST 2009


It seems that python will accept a .py file piped from stdin, but not a 
.pyc file (and there don't seem to be any flags to allow this). Am I 
missing something?


cat blah.py | python

works, but

cat blah.pyc | python

doesn't. (If you're wondering why anyone would do this it's because I'm 
actually intending to use curl rather than cat :)


More information about the Python-list mailing list