##// END OF EJS Templates
Avoid loading readline in the kernel...
Thomas Kluyver -
Show More
@@ -334,11 +334,12 b' Currently the magic system has the following functions:""",'
334 # local shortcut
334 # local shortcut
335 shell = self.shell
335 shell = self.shell
336
336
337 import IPython.utils.rlineimpl as readline
338
337
339 if not shell.colors_force and \
338
340 not readline.have_readline and \
339 if not shell.colors_force:
341 (sys.platform == "win32" or sys.platform == "cli"):
340 if sys.platform in {'win32', 'cli'}:
341 import IPython.utils.rlineimpl as readline
342 if not readline.have_readline:
342 msg = """\
343 msg = """\
343 Proper color support under MS Windows requires the pyreadline library.
344 Proper color support under MS Windows requires the pyreadline library.
344 You can find it at:
345 You can find it at:
@@ -348,8 +349,9 b' Defaulting color scheme to \'NoColor\'"""'
348 new_scheme = 'NoColor'
349 new_scheme = 'NoColor'
349 warn(msg)
350 warn(msg)
350
351
351 # readline option is 0
352 elif not shell.has_readline:
352 if not shell.colors_force and not shell.has_readline:
353 # Coloured prompts get messed up without readline
354 # Will remove this check after switching to prompt_toolkit
353 new_scheme = 'NoColor'
355 new_scheme = 'NoColor'
354
356
355 # Set prompt colors
357 # Set prompt colors
General Comments 0
You need to be logged in to leave comments. Login now