M
M
Mark2011-11-06 05:18:12
Python
Mark, 2011-11-06 05:18:12

How to override standard input and output of IPython?

Task: to replace the standard input and output of IPython.
What I did: replaced sys.{stdin,stdout,stderr}with my file-like objects.

from IPython.Shell import IPShellEmbed
IPShellEmbed()()

It works, but the output is sent to the shell from which the program is launched. You don't know why? Versions: IPython 0.10.2
, python - jython 2.5.2

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
susl, 2011-11-06
@printf

IPython.Shell.Term.cin/cout not working?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question