How do I update my PromptManager settings for IPython 5.0?

空扰寡人 提交于 2019-12-06 19:29:13

问题


The lines

# Output prompt. '\#' will be transformed to the prompt number
c.PromptManager.out_template = '{color.Green}Out[{count}]{color.Green} : {color.LightGray}'

# Continuation prompt.
c.PromptManager.in2_template = '{color.Yellow}   .\\D.{color.Green} : {color.LightGray}'

# If True (default), each prompt will be right-aligned with the preceding one.
c.PromptManager.justify = True

# Input prompt.  '\#' will be transformed to the prompt number
c.PromptManager.in_template = '{color.Green}In [{count}]{color.LightGreen} : {color.DarkGray}'

in my ipython_config.py give

usr/local/lib/python2.7/site-packages/IPython/core/interactiveshell.py:440: UserWarning: As of IPython 5.0 `PromptManager` config will have no effect and has been replaced by TerminalInteractiveShell.prompts_class
  warn('As of IPython 5.0 `PromptManager` config will have no effect'

but replacing PromptManager with TerminalInteractiveShell.prompts_class has no effect.

How do I update my PromptManager settings for IPython 5.0?

来源:https://stackoverflow.com/questions/38361607/how-do-i-update-my-promptmanager-settings-for-ipython-5-0

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!