From 0a44287ceb72de1d2b2008cdee89143f34a0b50a 2017-01-07 14:36:34 From: Srinivas Reddy Thatiparthy Date: 2017-01-07 14:36:34 Subject: [PATCH] remove dead code --- diff --git a/IPython/terminal/interactiveshell.py b/IPython/terminal/interactiveshell.py index 44efb10..a9d2162 100644 --- a/IPython/terminal/interactiveshell.py +++ b/IPython/terminal/interactiveshell.py @@ -342,26 +342,7 @@ class TerminalInteractiveShell(InteractiveShell): return import win_unicode_console - - if PY3: - win_unicode_console.enable() - else: - # https://github.com/ipython/ipython/issues/9768 - from win_unicode_console.streams import (TextStreamWrapper, - stdout_text_transcoded, stderr_text_transcoded) - - class LenientStrStreamWrapper(TextStreamWrapper): - def write(self, s): - if isinstance(s, bytes): - s = s.decode(self.encoding, 'replace') - - self.base.write(s) - - stdout_text_str = LenientStrStreamWrapper(stdout_text_transcoded) - stderr_text_str = LenientStrStreamWrapper(stderr_text_transcoded) - - win_unicode_console.enable(stdout=stdout_text_str, - stderr=stderr_text_str) + win_unicode_console.enable() def init_io(self): if sys.platform not in {'win32', 'cli'}: