MCPcopy Create free account
hub / github.com/ipython/ipython / InteractiveShellApp

Class InteractiveShellApp

IPython/core/shellapp.py:103–441  ·  view source on GitHub ↗

A Mixin for applications that start InteractiveShell instances. Provides configurables for loading extensions and executing files as part of configuring a Shell environment. The following methods should be called by the :meth:`initialize` method of the subclass: - :meth:`ini

Source from the content-addressed store, hash-verified

101#-----------------------------------------------------------------------------
102
103class InteractiveShellApp(Configurable):
104 """A Mixin for applications that start InteractiveShell instances.
105
106 Provides configurables for loading extensions and executing files
107 as part of configuring a Shell environment.
108
109 The following methods should be called by the :meth:`initialize` method
110 of the subclass:
111
112 - :meth:`init_path`
113 - :meth:`init_shell` (to be implemented by the subclass)
114 - :meth:`init_gui_pylab`
115 - :meth:`init_extensions`
116 - :meth:`init_code`
117 """
118 extensions = List(Unicode(),
119 help="A list of dotted module names of IPython extensions to load."
120 ).tag(config=True)
121 extra_extension = Unicode('',
122 help="dotted module name of an IPython extension to load."
123 ).tag(config=True)
124
125 reraise_ipython_extension_failures = Bool(False,
126 help="Reraise exceptions encountered loading IPython extensions?",
127 ).tag(config=True)
128
129 # Extensions that are always loaded (not configurable)
130 default_extensions = List(Unicode(), [u'storemagic']).tag(config=False)
131
132 hide_initial_ns = Bool(True,
133 help="""Should variables loaded at startup (by startup files, exec_lines, etc.)
134 be hidden from tools like %who?"""
135 ).tag(config=True)
136
137 exec_files = List(Unicode(),
138 help="""List of files to run at IPython startup."""
139 ).tag(config=True)
140 exec_PYTHONSTARTUP = Bool(True,
141 help="""Run the file referenced by the PYTHONSTARTUP environment
142 variable at IPython startup."""
143 ).tag(config=True)
144 file_to_run = Unicode('',
145 help="""A file to be run""").tag(config=True)
146
147 exec_lines = List(Unicode(),
148 help="""lines of code to run at IPython startup."""
149 ).tag(config=True)
150 code_to_run = Unicode('',
151 help="Execute the given command string."
152 ).tag(config=True)
153 module_to_run = Unicode('',
154 help="Run the module as a script."
155 ).tag(config=True)
156 gui = CaselessStrEnum(gui_keys, allow_none=True,
157 help="Enable GUI event loop integration with any of {0}.".format(gui_keys)
158 ).tag(config=True)
159 matplotlib = CaselessStrEnum(backend_keys, allow_none=True,
160 help="""Configure matplotlib for interactive use with

Callers

nothing calls this directly

Calls 1

formatMethod · 0.45

Tested by

no test coverage detected