MCPcopy Index your code
hub / github.com/ipython/ipython / TerminalIPythonApp

Class TerminalIPythonApp

IPython/terminal/ipapp.py:187–330  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

185
186
187class TerminalIPythonApp(BaseIPythonApplication, InteractiveShellApp):
188 name = "ipython"
189 description = usage.cl_usage
190 crash_handler_class = IPAppCrashHandler # typing: ignore[assignment]
191 examples = _examples
192
193 flags = flags
194 aliases = aliases
195 classes = List()
196
197 interactive_shell_class = Type(
198 klass=object, # use default_value otherwise which only allow subclasses.
199 default_value=TerminalInteractiveShell,
200 help="Class to use to instantiate the TerminalInteractiveShell object. Useful for custom Frontends"
201 ).tag(config=True)
202
203 @default('classes')
204 def _classes_default(self):
205 """This has to be in a method, for TerminalIPythonApp to be available."""
206 return [
207 InteractiveShellApp, # ShellApp comes before TerminalApp, because
208 self.__class__, # it will also affect subclasses (e.g. QtConsole)
209 TerminalInteractiveShell,
210 HistoryManager,
211 MagicsManager,
212 ProfileDir,
213 PlainTextFormatter,
214 IPCompleter,
215 ScriptMagics,
216 LoggingMagics,
217 StoreMagics,
218 ]
219
220 subcommands = dict(
221 profile = ("IPython.core.profileapp.ProfileApp",
222 "Create and manage IPython profiles."
223 ),
224 kernel = ("ipykernel.kernelapp.IPKernelApp",
225 "Start a kernel without an attached frontend."
226 ),
227 locate=('IPython.terminal.ipapp.LocateIPythonApp',
228 LocateIPythonApp.description
229 ),
230 history=('IPython.core.historyapp.HistoryApp',
231 "Manage the IPython history database."
232 ),
233 )
234
235 # *do* autocreate requested profile, but don't create the config file.
236 auto_create = Bool(True).tag(config=True)
237
238 # configurables
239 quick = Bool(False,
240 help="""Start IPython quickly by skipping the loading of config files."""
241 ).tag(config=True)
242 @observe('quick')
243 def _quick_changed(self, change):
244 if change['new']:

Callers 2

autogen_config.pyFile · 0.90
load_default_configFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…