[IPython-dev] How to print stderr in qtconsole?
Wed Jun 19 19:58:57 CDT 2013
Thanks a lot for the tip. I decided to patch unittest.main (through our
sitecustomize) so that it has the same testRunner arg as the one you
mentioned. It seems overkilling that the user needs to pass it directly
just to run his tests.
El 10/06/13 20:47, MinRK escribió:
> It's probably an issue of unittest hooking up to `sys.__stderr__`
> instead of `sys.stderr`. We don't (and shouldn't) redirect the
> lower-level private handle, but you can tell it to use `sys.stderr`
> import sys
> import unittest
> class tests(unittest.TestCase):
> def test_raise(self):
> print 1 / 0
> if __name__ == '__main__':
> which should display output just fine in the QtConsole.
> IPython-dev mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the IPython-dev