You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes - this is a silly thing that we need to figure out. The 'colors' cl_arg sets InteractiveShell.colors. You have set TerminalInteractiveShell.colors, which is a subclass, and thus takes precedence. So when you have colors set in your config, and *also* at the command-line, you will be starting up IPython with config:
c.InteractiveShell.colors = 'NoColor'
c.TerminalInteractiveShell.colors = 'Linux'
Now, if you change your config file to specify InteractiveShell.colors instead of TerminalInteractiveShell.colors, the cl-arg will properly override.
What we should really do is adjust the cl-arg system, such that it maps somehow to all subclasses, or possibly just the lowest active subclass, so it always gets highest priority.
The text was updated successfully, but these errors were encountered:
minrk
added a commit
to minrk/ipython
that referenced
this issue
Oct 10, 2011
…iles
add Application.flatten_flags() method, which adjusts the alias
and flag dicts, such that they point to the subclass in the Application.classes list when passed to the argv parser.
This prevents TerminalInteractiveShell.colors in a config file overriding
`--colors` on the command-line, which points to InteractiveShell.colors.
Flattening is only done when the answer is unambiguous, so multiply inherited classes (e.g. Launchers in ipcluster) are not touched.
also remove now-obsolete manual workaround for this in IPClusterStart
closesipythongh-849
…iles
add Application.flatten_flags() method, which adjusts the alias
and flag dicts, such that they point to the subclass in the Application.classes list when passed to the argv parser.
This prevents TerminalInteractiveShell.colors in a config file overriding
`--colors` on the command-line, which points to InteractiveShell.colors.
Flattening is only done when the answer is unambiguous, so multiply inherited classes (e.g. Launchers in ipcluster) are not touched.
also remove now-obsolete manual workaround for this in IPClusterStart
closesipythongh-849
See http://mail.scipy.org/pipermail/ipython-user/2011-October/008549.html. I don't have a full understanding of the issue, so I hope that nothing I say here is wrong. If I run
ipython --colors=NoColor
, it doesn't work, because I havec.TerminalInteractiveShell.colors ='Linux'
set in my profile (see https://github.com/asmeurer/dotfiles/blob/master/.ipython/profile_default/ipython_config.py). To quote Min from the IPython mailing listThe text was updated successfully, but these errors were encountered: