It might work, sys.stdin = open(sys.stdin.fileno(), 'r', <Data descriptors>)
or Simply for replacing iostream, sys.stdin = open(<filepath> ,'r') On Mon, Aug 4, 2014 at 3:48 PM, Rohit Chormale <rohitchorm...@gmail.com> wrote: > > Hi Nitin, > > Do u mean redirecting Standard IO streams? > > > On Mon, Aug 4, 2014 at 3:08 PM, Noufal Ibrahim KV <nou...@nibrahim.net.in> > wrote: > >> On Mon, Aug 04 2014, Nitin Kumar wrote: >> >> > thats a typo error. >> > >> > in simple term my question would be: How to override sys.stdin. >> >> [...] >> >> The StringIO module gives you file like objects into which you can put >> data. They might work as substitues for sys.std* >> >> -- >> Cordially, >> Noufal >> http://nibrahim.net.in >> _______________________________________________ >> BangPypers mailing list >> BangPypers@python.org >> https://mail.python.org/mailman/listinfo/bangpypers >> > > _______________________________________________ BangPypers mailing list BangPypers@python.org https://mail.python.org/mailman/listinfo/bangpypers