ipython API reference
315 public APIs from ipython (ipython/ipython) — 103 classes, 115 functions, 97 methods. Signatures extracted by static analysis of the actual source.
Repository: ipython/ipython
| Kind | Count |
|---|---|
| Classes | 103 |
| Functions | 115 |
| Methods | 97 |
API list
class
IPython.core.alias.AliasCallable object storing the details of one alias.
func
IPython.core.alias.default_aliases() -> list[tuple[str, str]]Return list of shell aliases to auto-define.
class
IPython.core.autocall.ZMQExitAutocallExit IPython.
func
IPython.core.compilerop.code_name(code:str, number:int=0) -> strCompute a (probably) unique name for code for caching.
class
IPython.core.completer.CompletionCompletion object used and returned by IPython completers.
method
IPython.core.completer.IPCompleter.all_completions(text:str) -> list[str]Wrapper around the completion methods for the benefit of emacs.
method
IPython.core.completer.IPCompleter.completions(text:str, offset:int) -> Iterator[Completion]Returns an iterator over the possible completions ..
method
IPython.core.completer.IPCompleter.custom_completer_matcher(context:CompletionContext) -> SimpleMatcherResultDispatch custom completer.
method
IPython.core.completer.IPCompleter.dict_key_matcher(context:CompletionContext) -> SimpleMatcherResultMatch string keys in a dictionary, after e.g.
method
IPython.core.completer.IPCompleter.dict_key_matches(text:str) -> list[str]Match string keys in a dictionary, after e.g.
method
IPython.core.completer.IPCompleter.dispatch_custom_completer(text:str) -> list[str] | None..
method
IPython.core.completer.IPCompleter.file_matcher(context:CompletionContext) -> SimpleMatcherResultMatch filenames, expanding ~USER type strings.
method
IPython.core.completer.IPCompleter.latex_matches(text:str) -> tuple[str, Sequence[str]]Match Latex syntax for unicode characters.
method
IPython.core.completer.IPCompleter.latex_name_matcher(context:CompletionContext) -> SimpleMatcherResultMatch Latex syntax for unicode characters.
method
IPython.core.completer.IPCompleter.magic_color_matcher(context:CompletionContext) -> SimpleMatcherResultMatch color schemes for %colors magic.
method
IPython.core.completer.IPCompleter.magic_config_matcher(context:CompletionContext) -> SimpleMatcherResultMatch class names and attributes for %config magic.
method
IPython.core.completer.IPCompleter.magic_config_matches(text:str) -> list[str]Match class names and attributes for %config magic.
method
IPython.core.completer.IPCompleter.magic_matcher(context:CompletionContext) -> SimpleMatcherResultMatch magics.
method
IPython.core.completer.IPCompleter.matchers() -> list[Matcher]All active matcher routines for completion
method
IPython.core.completer.IPCompleter.python_func_kw_matches(text:str) -> list[str]Match named parameters (kwargs) of the last open function.
method
IPython.core.completer.IPCompleter.python_matcher(context:CompletionContext) -> SimpleMatcherResultMatch attributes or global python names
class
IPython.core.completer.MatcherAPIv2Protocol describing Matcher API v2.
class
IPython.core.completer.SimpleMatcherResultResult of new-style completion matcher.
func
IPython.core.completer.completion_matcher(*priority:float | None=None, *identifier:str | None=None, *api_version:int=1) -> Callable[[Matcher], Matcher]Adds attributes describing the matcher.
func
IPython.core.completer.compress_user(path:str, tilde_expand:bool, tilde_val:str) -> strDoes the opposite of expand_user, with its outputs.
func
IPython.core.completer.expand_user(path:str) -> tuple[str, bool, str]Expand ``~``-style usernames in strings.
func
IPython.core.completer.get__all__entries(obj:Any) -> list[str]returns the strings in the __all__ attribute
func
IPython.core.completer.has_any_completions(result:MatcherResult) -> boolCheck if any result includes any completions.
func
IPython.core.completer.has_open_quotes(s:str) -> str | boolReturn whether a string has open quotes.
func
IPython.core.completer.protect_filename(s:str, protectables:str=PROTECTABLES) -> strEscape a string to protect certain characters.
func
IPython.core.completerlib.reset_completer(self, event)A completer for %reset magic
class
IPython.core.crashhandler.CrashHandlerCustomizable crash handlers for IPython applications.
method
IPython.core.crashhandler.CrashHandler.make_report(traceback:str) -> strReturn a string containing a crash report.
class
IPython.core.debugger.PdbModified Pdb class, does not load readline.
method
IPython.core.debugger.Pdb.do_pdoc(arg)Print the docstring for an object.
method
IPython.core.debugger.Pdb.format_stack_entry(frame_lineno:tuple[FrameType, int], lprefix:str=': ') -> stroverwrite from super class so must -> str
method
IPython.core.debugger.Pdb.print_stack_entry(frame_lineno:tuple[FrameType, int], prompt_prefix:str='\n-> ') -> NoneOverwrite print_stack_entry from superclass (PDB)
func
IPython.core.debugger.set_trace(frame=None, header=None)Start debugging from `frame`.
class
IPython.core.display.DisplayObjectAn object that wraps data to be displayed.
method
IPython.core.display.DisplayObject.reload()Reload the raw data from file or URL.
method
IPython.core.display.Image.reload()Reload the raw data from file or URL.
class
IPython.core.display.ProgressBarProgressbar supports displaying a progressbar like element
class
IPython.core.display.SVGEmbed an SVG into the display.
class
IPython.core.display.TextDisplayObjectCreate a text display object given raw data.
class
IPython.core.display_trap.DisplayTrapObject to manage sys.displayhook.
method
IPython.core.display_trap.DisplayTrap.set()Set the hook.
method
IPython.core.display_trap.DisplayTrap.unset()Unset the hook.
class
IPython.core.displayhook.DisplayHookThe custom IPython displayhook to replace sys.displayhook.
method
IPython.core.displayhook.DisplayHook.log_output(format_dict)Log the output.
method
IPython.core.displayhook.DisplayHook.write_format_data(format_dict, md_dict=None) -> NoneWrite the format data dict to the frontend.
method
IPython.core.displayhook.DisplayHook.write_output_prompt()Write the output prompt.
class
IPython.core.displaypub.CapturingDisplayPublisherA DisplayPublisher that stores
class
IPython.core.displaypub.DisplayPublisherA traited class that publishes display data to frontends.
class
IPython.core.error.InputRejectedInput rejected by ast transformer.
class
IPython.core.error.TryNextTry next hook exception.
class
IPython.core.error.UsageErrorError in magic function arguments, etc.
method
IPython.core.events.EventManager.register(event:str, function:Callable[..., Any]) -> NoneRegister a new event callback.
method
IPython.core.events.EventManager.trigger(event:str, *args:Any, **kwargs:Any) -> NoneCall callbacks for ``event``.
method
IPython.core.events.EventManager.unregister(event:str, function:Callable[..., Any]) -> NoneRemove a callback from the given event.
func
IPython.core.events.post_run_cell(result:ExecutionResult) -> NoneFires after user-entered code runs.
func
IPython.core.events.pre_run_cell(info:ExecutionInfo) -> NoneFires before user-entered code runs.
class
IPython.core.extensions.ExtensionManagerA class to manage IPython extensions.
class
IPython.core.formatters.BaseFormatterA base formatter class that is configurable.
method
IPython.core.formatters.BaseFormatter.lookup(obj)Look up the formatter for a given instance.
method
IPython.core.formatters.BaseFormatter.lookup_by_type(typ)Look up the registered formatter for a type.
method
IPython.core.formatters.BaseFormatter.pop(typ, default=_raise_key_error)Pop a formatter for the given type.
class
IPython.core.formatters.FormatterABCAbstract base class for Formatters.
class
IPython.core.formatters.FormatterWarningWarning class for errors in formatters
class
IPython.core.formatters.HTMLFormatterAn HTML formatter.
class
IPython.core.formatters.JPEGFormatterA JPEG formatter.
class
IPython.core.formatters.JSONFormatterA JSON string formatter.
class
IPython.core.formatters.JavascriptFormatterA Javascript formatter.
class
IPython.core.formatters.LatexFormatterA LaTeX formatter.
class
IPython.core.formatters.MarkdownFormatterA Markdown formatter.
class
IPython.core.formatters.MimeBundleFormatterA Formatter for arbitrary mime-types.
class
IPython.core.formatters.PDFFormatterA PDF formatter.
class
IPython.core.formatters.PNGFormatterA PNG formatter.
class
IPython.core.formatters.PlainTextFormatterThe default pretty-printer.
class
IPython.core.formatters.SVGFormatterAn SVG formatter.
func
IPython.core.formatters.catch_format_error(method)show traceback on failed format call
func
IPython.core.getipython.get_ipython() -> 'InteractiveShell | None'Get the global InteractiveShell instance.
class
IPython.core.guarded_eval.EvaluationPolicyDefinition of evaluation policy.
class
IPython.core.guarded_eval.GuardRejectionException raised when guard rejects evaluation attempt.
func
IPython.core.guarded_eval.eval_node(node:ast.AST | None, context:EvaluationContext)Evaluate AST node in provided context.
func
IPython.core.guarded_eval.guarded_eval(code:str, context:EvaluationContext)Evaluate provided code in the evaluation context.
class
IPython.core.history.DummyDBDummy DB that will act as a black hole for history.
class
IPython.core.history.HistoryAccessorAccess the history database without adding to it.
method
IPython.core.history.HistoryAccessor.close() -> NoneClose the SQLite database connection.
method
IPython.core.history.HistoryAccessor.get_last_session_id() -> int | NoneGet the last session ID currently in the database.
method
IPython.core.history.HistoryAccessor.get_range(session:int, start:int=1, stop:int | None=None, raw:bool=True, output:bool=False) -> Iterable[tuple[int, int, InOrInOut]]Retrieve input by session.
method
IPython.core.history.HistoryAccessor.get_session_info(session:int) -> tuple[int, datetime.datetime, datetime.datetime | None, int | None, str]Get info about a session.
method
IPython.core.history.HistoryAccessor.init_db() -> NoneConnect to the database, and create tables if necessary.
class
IPython.core.history.HistoryAccessorBaseAn abstract class for History Accessors
func
IPython.core.history.only_when_enabled(f:t.Callable[_P, _R]) -> t.Callable[_P, _R]Decorator: return an empty list in the absence of sqlite.
func
IPython.core.hooks.clipboard_get(self)Get text from the clipboard.
func
IPython.core.hooks.show_in_pager(self, data, start, screen_lines)Run a string through pager
class
IPython.core.inputtransformer2.EscapedCommandTransformer for escaped commands like %foo, !foo, or /foo
class
IPython.core.inputtransformer2.HelpEndTransformer for help syntax: obj?
class
IPython.core.inputtransformer2.MagicAssignTransformer for assignments from magics (a = %foo)
class
IPython.core.inputtransformer2.PromptStripperRemove matching input prompts from a block of input.
class
IPython.core.inputtransformer2.TokenTransformBaseBase class for transformations which examine tokens.
class
IPython.core.inputtransformer2.TransformerManagerApplies various transformations to a cell or code block.
method
IPython.core.inputtransformer2.TransformerManager.transform_cell(cell:str) -> strTransforms a cell of input code
func
IPython.core.inputtransformer2.leading_indent(lines)Remove leading indentation.
class
IPython.core.interactiveshell.InteractiveShellAn enhanced, interactive shell for Python.
method
IPython.core.interactiveshell.InteractiveShell.debugger(force=False)Call the pdb debugger.
method
IPython.core.interactiveshell.InteractiveShell.run_code(code_obj, result=None, *async_=False)Execute a code object.
method
IPython.core.interactiveshell.InteractiveShell.run_line_magic(magic_name:str, line:str, _stack_depth=1)Execute the given line magic.
method
IPython.core.interactiveshell.InteractiveShell.set_autoindent(value=None)Set the autoindent flag.
method
IPython.core.interactiveshell.InteractiveShell.set_custom_completer(completer, pos=0) -> NoneAdds a new custom completer function.
method
IPython.core.interactiveshell.InteractiveShell.show_usage()Show a usage message
class
IPython.core.interactiveshell.InteractiveShellABCAn abstract base class for InteractiveShell.
class
IPython.core.interactiveshell.ProvisionalWarningWarning class for unstable features
class
IPython.core.logger.LoggerA Logfile class with different policies for file creation
method
IPython.core.logger.Logger.log(line_mod:str, line_ori:str) -> NoneWrite the sources to a log.
method
IPython.core.logger.Logger.log_write(data:str, kind:str='input') -> NoneWrite data to the log file, if active
method
IPython.core.logger.Logger.logstate() -> NonePrint a status message about the logger.
method
IPython.core.logger.Logger.logstop() -> NoneFully stop logging and close log file.
method
IPython.core.logger.Logger.switch_log(val:bool) -> NoneSwitch logging on/off.
class
IPython.core.macro.MacroSimple class to store the value of macros as strings.
class
IPython.core.magic.MagicAliasAn alias to another magic function.
class
IPython.core.magic.MagicsBase class for implementing magic functions.
method
IPython.core.magic.Magics.arg_err(func:Callable[..., Any]) -> NonePrint docstring if incorrect arguments were passed
method
IPython.core.magic.Magics.format_latex(strng:str) -> strFormat a string for latex inclusion.
method
IPython.core.magic.Magics.parse_options(arg_str:str, opt_str:str, *long_opts:str, **kw:Any) -> tuple[Any, Any]Parse options passed to an argument string.
method
IPython.core.magic.MagicsManager.auto_status() -> strReturn descriptive string with automagic status.
method
IPython.core.magic.MagicsManager.lsmagic() -> dict[str, dict[str, Any]]Return a dict of currently available magic functions.
method
IPython.core.magic.MagicsManager.lsmagic_docs(brief:bool=False, missing:str='') -> dict[str, dict[str, str]]Return dict of documentation of magic functions.
method
IPython.core.magic.MagicsManager.register(*magic_objects:type[Magics] | Magics) -> NoneRegister one or more instances of Magics.
method
IPython.core.magic.MagicsManager.register_alias(alias_name:str, magic_name:str, magic_kind:_MagicKind='line', magic_params:str | None=None) -> NoneRegister an alias to a magic function.
method
IPython.core.magic.MagicsManager.register_lazy(name:str, fully_qualified_name:str) -> NoneLazily register a magic via an extension.
func
IPython.core.magic.compress_dhist(dh:list[str]) -> list[str]Compress a directory history into a new one with at most 20 entries.
func
IPython.core.magic.magics_class(cls:_T) -> _TClass decorator for all subclasses of the main Magics class.
func
IPython.core.magic.needs_local_scope(func:_F) -> _FDecorator to mark magic functions which need to local scope to run.
func
IPython.core.magic.output_can_be_silenced(magic_func:_F) -> _FMark a magic function so its output may be silenced.
func
IPython.core.magic.validate_type(magic_kind:str) -> NoneEnsure that the given magic_kind is valid.
class
IPython.core.magic_arguments.ArgMethodWrapperBase class to define a wrapper for ArgumentParser method.
class
IPython.core.magic_arguments.MagicArgumentParserAn ArgumentParser tweaked for use by IPython magics.
class
IPython.core.magic_arguments.argumentStore arguments and keywords to pass to add_argument().
class
IPython.core.magic_arguments.defaultsStore arguments and keywords to pass to set_defaults().
class
IPython.core.magic_arguments.kwdsProvide other keywords to the sub-parser constructor.
func
IPython.core.magic_arguments.real_name(magic_func)Find the real name of the magic.
class
IPython.core.magics.UserMagicsPlaceholder for user-defined magics to be added at runtime.
class
IPython.core.magics.auto.AutoMagicsMagics that control various autoX behaviors.
class
IPython.core.magics.basic.BasicMagicsMagics that provide central IPython functionality.
method
IPython.core.magics.basic.BasicMagics.doctest_mode(parameter_s='')Toggle doctest mode on and off.
method
IPython.core.magics.basic.BasicMagics.pprint(parameter_s='')Toggle pretty printing on/off.
method
IPython.core.magics.basic.BasicMagics.quickref(arg)Show a quick reference sheet
class
IPython.core.magics.execution.TimeitTemplateFillerFill in the AST template for timing execution.
method
IPython.core.magics.execution.TimeitTemplateFiller.visit_FunctionDef(node)Fill in the setup statement
class
IPython.core.magics.extension.ExtensionMagicsMagics to manage the IPython extensions system.
class
IPython.core.magics.logging.LoggingMagicsMagics related to all logging machinery.
method
IPython.core.magics.logging.LoggingMagics.logoff(parameter_s='')Temporarily stop logging.
method
IPython.core.magics.logging.LoggingMagics.logon(parameter_s='')Restart logging.
class
IPython.core.magics.namespace.NamespaceMagicsMagics to manage various aspects of the user's namespace.
class
IPython.core.magics.packaging.PackagingMagicsMagics related to packaging & installation
class
IPython.core.magics.pylab.PylabMagicsMagics related to matplotlib's pylab support
func
IPython.core.magics.script.script_args(f)single decorator for adding script args
method
IPython.core.oinspect.Inspector.psource(obj, oname='')Print the source code for an object.
class
IPython.core.oinspect.InspectorHookDataData passed to the mime hook
func
IPython.core.oinspect.getdoc(obj) -> str | NoneStable wrapper around inspect.getdoc.
func
IPython.core.oinspect.getsource(obj, oname='') -> str | NoneWrapper around inspect.getsource.
func
IPython.core.oinspect.is_simple_callable(obj)True if obj is a function ()
func
IPython.core.oinspect.object_info(*name:str, *found:bool, *isclass:bool=False, *isalias:bool=False, *ismagic:bool=False, **kw) -> InfoDictMake an object info dict with all fields present.
func
IPython.core.page.display_page(strng, start=0, screen_lines=25)Just display, no paging.
func
IPython.core.page.get_pager_cmd(pager_cmd=None)Return a pager command.
class
IPython.core.prefilter.PrefilterCheckerInspect an input line and return a handler for that line.
class
IPython.core.prefilter.PrefilterManagerMain prefilter component.
method
IPython.core.prefilter.PrefilterManager.get_handler_by_name(name)Get a handler by its name.
method
IPython.core.prefilter.PrefilterManager.handlers()Return a dict of all the handlers.
method
IPython.core.prefilter.PrefilterManager.init_checkers()Create the default checkers.
method
IPython.core.prefilter.PrefilterManager.init_handlers()Create the default handlers.
method
IPython.core.prefilter.PrefilterManager.register_checker(checker)Register a checker instance.
method
IPython.core.prefilter.PrefilterManager.sort_checkers()Sort the checkers by priority.
method
IPython.core.prefilter.PrefilterManager.sort_transformers()Sort the transformers by priority.
method
IPython.core.prefilter.PrefilterManager.unregister_checker(checker)Unregister a checker instance.
class
IPython.core.prefilter.PrefilterTransformerTransform a line of user input.
class
IPython.core.profiledir.ProfileDirAn object to manage the profile directory and its resources.
class
IPython.core.splitinput.LineInfoA single line of input and associated info.
class
IPython.core.tbtools.TBToolsBasic tools used by all traceback printer classes.
method
IPython.core.tbtools.TBTools.set_colors(name:str) -> NoneShorthand access to the color table scheme selector method.
method
IPython.core.tbtools.TBTools.stb2text(stb:list[str]) -> strConvert a structured traceback (a list) to a string.
method
IPython.core.tbtools.TBTools.structured_traceback(etype:type, evalue:BaseException | None, etb:TracebackType | None=None, tb_offset:int | None=None, context:int=5) -> list[str]Return a list of traceback frames.
method
IPython.core.tbtools.TBTools.text(etype:type, value:BaseException | None, tb:TracebackType | None, tb_offset:int | None=None, context:int=5) -> strReturn formatted traceback.
func
IPython.core.tbtools.text_repr(value:Any) -> strHopefully pretty robust repr equivalent.
class
IPython.core.ultratb.AutoFormattedTBA traceback printer which can be called on the fly.
class
IPython.core.ultratb.ColorTBDeprecated since IPython 9.0.
class
IPython.core.ultratb.FormattedTBSubclass ListTB but allow calling with a traceback.
method
IPython.core.ultratb.FormattedTB.set_mode(mode:str | None=None) -> NoneSwitch to the desired mode.
method
IPython.core.ultratb.FormattedTB.stb2text(stb:list[str]) -> strConvert a structured traceback (a list) to a string.
class
IPython.core.ultratb.SyntaxTBExtension which holds some state: the last exception value
method
IPython.core.ultratb.SyntaxTB.clear_err_state() -> Any | NoneReturn the current error state and clear it
method
IPython.core.ultratb.SyntaxTB.stb2text(stb:list[str]) -> strConvert a structured traceback (a list) to a string.
func
IPython.extensions.autoreload.load_ipython_extension(ip)Load the extension in IPython.
class
IPython.extensions.deduperreload.deduperreload.DependencyNodeEach node represents a function.
class
IPython.extensions.storemagic.StoreMagicsLightweight persistence for python variables.
func
IPython.extensions.storemagic.load_ipython_extension(ip)Load the extension in IPython.
class
IPython.lib.backgroundjobs.BackgroundJobBaseBase class to build BackgroundJob classes.
class
IPython.lib.backgroundjobs.BackgroundJobManagerClass to manage a pool of backgrounded threaded jobs.
func
IPython.lib.clipboard.osx_clipboard_get() -> strGet the clipboard's text on OS X.
func
IPython.lib.deepreload.add_submodule(mod, submod, fullname, subname)mod.{subname} = submod
func
IPython.lib.deepreload.deep_reload_hook(m)Replacement for reload().
class
IPython.lib.demo.ClearMixinUse this mixin to make Demo classes with less visual clutter.
class
IPython.lib.demo.LineDemoDemo where each line is executed as a separate block.
class
IPython.lib.display.AudioCreate an audio object.
method
IPython.lib.display.Audio.reload()Reload the raw data from file or URL.
class
IPython.lib.display.CodeDisplay syntax-highlighted source code.
class
IPython.lib.display.IFrameGeneric class to embed an iframe in an IPython notebook
func
IPython.lib.editorhooks.jed(exe='jed')JED, the lightweight emacsish editor
func
IPython.lib.editorhooks.komodo(exe='komodo')Activestate Komodo [Edit]
func
IPython.lib.editorhooks.mate(exe='mate')TextMate, the missing editor
func
IPython.lib.editorhooks.scite(exe='scite')SciTE or Sc1
func
IPython.lib.guisupport.is_event_loop_running_qt4(app=None)Is the qt event loop running.
func
IPython.lib.guisupport.is_event_loop_running_wx(app=None)Is the wx event loop running.
class
IPython.lib.latextools.LaTeXToolAn object to store configuration of the LaTeX tool.
func
IPython.lib.latextools.latex_to_png(s:str, encode=False, backend=None, wrap=False, color='Black', scale=1.0)Render a LaTeX string to PNG.
method
IPython.lib.pretty.PrettyPrinter.begin_group(indent=0, open='')Begin a group.
method
IPython.lib.pretty.PrettyPrinter.end_group(dedent=0, close='')End a group.
method
IPython.lib.pretty.PrettyPrinter.flush()Flush data that is left in the buffer.
method
IPython.lib.pretty.PrettyPrinter.text(obj)Add literal text to the output.
class
IPython.lib.pretty.RawStringLiteralWrapper that shows a string with a `r` prefix
func
IPython.lib.pretty.for_type(typ, func)Add a pretty printer for a given type.
func
IPython.paths.get_ipython_cache_dir() -> strGet the cache directory it is created if it does not exist.
func
IPython.paths.get_ipython_dir() -> strGet the IPython directory for this platform and user.
func
IPython.paths.get_ipython_package_dir() -> strGet the base directory where IPython itself is installed.
func
IPython.paths.locate_profile(profile:str='default') -> strFind the path to the folder associated with a given profile.
class
IPython.sphinxext.ipython_directive.EmbeddedSphinxShellAn embedded IPython instance to run inside Sphinx
class
IPython.terminal.debugger.TerminalPdbStandalone IPython debugger.
func
IPython.terminal.debugger.set_trace(frame=None)Start debugging from `frame`.
class
IPython.terminal.prompts.RichPromptDisplayHookSubclass of base display hook using coloured prompt
func
IPython.terminal.pt_inputhooks.osx.C(classname)get an ObjC Class by name
func
IPython.terminal.pt_inputhooks.osx.inputhook(context)Inputhook for Cocoa (NSApp)
func
IPython.terminal.pt_inputhooks.osx.n(name)create a selector name (for ObjC methods)
func
IPython.terminal.pt_inputhooks.tk.inputhook(inputhook_context)Inputhook for Tk.
class
IPython.terminal.ptutils.IPythonPTCompleterAdaptor to provide IPython completions to prompt_toolkit
class
IPython.terminal.ptutils.IPythonPTLexerWrapper around PythonLexer and BashLexer.
func
IPython.terminal.shortcuts.auto_match.braces(event:KeyPressEvent)Auto-close braces
func
IPython.terminal.shortcuts.auto_match.brackets(event:KeyPressEvent)Auto-close brackets
func
IPython.terminal.shortcuts.auto_match.delete_pair(event:KeyPressEvent)Delete auto-closed parenthesis
func
IPython.terminal.shortcuts.auto_match.docstring_double_quotes(event:KeyPressEvent)Auto-close docstring (double quotes)
func
IPython.terminal.shortcuts.auto_match.docstring_single_quotes(event:KeyPressEvent)Auto-close docstring (single quotes)
func
IPython.terminal.shortcuts.auto_match.double_quote(event:KeyPressEvent)Auto-close double quotes
func
IPython.terminal.shortcuts.auto_match.parenthesis(event:KeyPressEvent)Auto-close parenthesis
func
IPython.terminal.shortcuts.auto_match.raw_string_braces(event:KeyPressEvent)Auto-close braces in raw strings
func
IPython.terminal.shortcuts.auto_match.raw_string_bracket(event:KeyPressEvent)Auto-close bracker in raw strings
func
IPython.terminal.shortcuts.auto_match.raw_string_parenthesis(event:KeyPressEvent)Auto-close parenthesis in raw strings
func
IPython.terminal.shortcuts.auto_match.single_quote(event:KeyPressEvent)Auto-close single quotes
func
IPython.terminal.shortcuts.auto_suggest.accept(event:KeyPressEvent)Accept autosuggestion
func
IPython.terminal.shortcuts.auto_suggest.accept_character(event:KeyPressEvent)Fill partial autosuggestion by character
func
IPython.terminal.shortcuts.auto_suggest.accept_token(event:KeyPressEvent)Fill partial autosuggestion by token
func
IPython.terminal.shortcuts.auto_suggest.accept_word(event:KeyPressEvent)Fill partial autosuggestion by word
func
IPython.terminal.shortcuts.auto_suggest.discard(event:KeyPressEvent)Discard autosuggestion
func
IPython.terminal.shortcuts.auto_suggest.down_and_update_hint(event:KeyPressEvent)Go down and update hint
func
IPython.terminal.shortcuts.auto_suggest.resume_hinting(event:KeyPressEvent)Resume autosuggestions
func
IPython.terminal.shortcuts.auto_suggest.swap_autosuggestion_up(event:KeyPressEvent)Get next autosuggestion from history.
func
IPython.terminal.shortcuts.auto_suggest.up_and_update_hint(event:KeyPressEvent)Go up and update hint
func
IPython.terminal.shortcuts.dismiss_completion(event)Dismiss completion
func
IPython.terminal.shortcuts.indent_buffer(event)Indent buffer
func
IPython.terminal.shortcuts.reformat_and_execute(event)Reformat code and execute it
func
IPython.terminal.shortcuts.reset_buffer(event)Reset buffer
func
IPython.terminal.shortcuts.reset_search_buffer(event)Reset search buffer
func
IPython.terminal.shortcuts.suspend_to_bg(event)Suspend to background
class
IPython.utils.PyColorize.ParserFormat colored Python source.
method
IPython.utils.PyColorize.Parser.format2(raw:str, out:Any=None) -> tuple[str | None, bool]Parse and send the colored source.
method
IPython.utils.PyColorize.Theme.make_arrow(width:int) -> strgenerate the leading arrow in front of traceback or debugger
func
IPython.utils._process_common.arg_split(commandline:str, posix:bool=False, strict:bool=True) -> list[str]Split a command line's arguments in a shell-like manner.
func
IPython.utils._process_common.getoutput(cmd:str | list[str]) -> strRun a command and return its stdout/stderr as a string.
func
IPython.utils._process_common.read_no_interrupt(stream:IO[bytes]) -> bytes | NoneRead from a pipe ignoring EINTR errors.
class
IPython.utils._process_posix.ProcessHandlerExecute subprocesses under the control of pexpect.
method
IPython.utils._process_posix.ProcessHandler.getoutput(cmd:str) -> str | NoneRun a command and return its stdout/stderr as a string.
method
IPython.utils._process_posix.ProcessHandler.system(cmd:str) -> intExecute a command in a subshell.
class
IPython.utils._process_win32.AvoidUNCPathA context manager to protect command execution from UNC paths.
func
IPython.utils._process_win32.arg_split(commandline:str, posix:bool=False, strict:bool=True) -> list[str]Split a command line's arguments in a shell-like manner.
func
IPython.utils._process_win32.getoutput(cmd:str) -> strReturn standard output of executing cmd in a shell.
func
IPython.utils._process_win32.system(cmd:str) -> int | NoneWin32 version of os.system() that works with network shares.
class
IPython.utils.capture.capture_outputcontext manager for capturing stdout/err
class
IPython.utils.contexts.preserve_keysPreserve a set of keys in a dictionary.
func
IPython.utils.data.chop(seq:Sequence[T], size:int) -> list[Sequence[T]]Chop a sequence into chunks of the given size.
func
IPython.utils.data.uniq_stable(elems:Iterable[T]) -> list[T]uniq_stable(elems) -> list ..
func
IPython.utils.decorators.flag_calls(func:Callable[..., Any]) -> Callable[..., Any]Wrap a function to detect and flag when it gets called.
func
IPython.utils.decorators.sphinx_options(show_inheritance:bool=True, show_inherited_members:bool=False, exclude_inherited_from:Sequence[str]=tuple()) -> Callable[[F], F]Set sphinx options
func
IPython.utils.decorators.undoc(func:F) -> FMark a function or class as undocumented.
func
IPython.utils.dir2.safe_hasattr(obj:object, attr:str) -> boolIn recent versions of Python, hasattr() only catches AttributeError.
func
IPython.utils.encoding.get_stream_enc(stream:Any, default:str | None=None) -> str | NoneReturn the given stream's encoding or a default.
func
IPython.utils.generics.complete_object(obj:Any, prev_completions:list[str]) -> list[str]Custom completer dispatching for python objects.
func
IPython.utils.importstring.import_item(name:str) -> AnyImport and return ``bar`` given the string ``foo.bar``.
class
IPython.utils.io.TeeA class to duplicate an output stream to stdout/err.
method
IPython.utils.io.Tee.close()Close the file and restore the channel.
method
IPython.utils.io.Tee.flush()Flush both channels.
method
IPython.utils.io.Tee.write(data)Write data to both channels.
func
IPython.utils.io.temp_pyfile(src:str, ext:str='.py') -> strMake a temporary python file, return filename and filehandle.
class
IPython.utils.ipstruct.StructA dict subclass with attribute style access.
method
IPython.utils.ipstruct.Struct.copy()Return a copy as a Struct.
method
IPython.utils.ipstruct.Struct.hasattr(key)hasattr function available as a method.
func
IPython.utils.path.compress_user(path:str) -> strReverse of :func:`os.path.expanduser`
func
IPython.utils.path.filefind(filename:str, path_dirs=None) -> strFind a file by looking through a sequence of paths.
func
IPython.utils.path.get_home_dir(require_writable:bool=False) -> strReturn the 'home' directory, as a unicode string.
func
IPython.utils.path.get_long_path_name(path)Expand a path into its long form.
func
IPython.utils.path.unescape_glob(string)Unescape glob pattern in `string`.
func
IPython.utils.process.abbrev_cwd()Return abbreviated version of cwd, e.g.
class
IPython.utils.strdispatch.StrDispatchDispatch (lookup) a set of strings / regexps for match.
method
IPython.utils.strdispatch.StrDispatch.add_s(s:str, obj:Callable, priority:int=0)Adds a target 'string' for dispatching
func
IPython.utils.terminal.set_term_title(title:str) -> NoneSet terminal title using the necessary platform-dependent calls.
func
IPython.utils.terminal.toggle_set_term_title(val:bool)Control whether set_term_title is active or not.
class
IPython.utils.text.LSStringString derivative with a special access attributes.
class
IPython.utils.text.SListList derivative with a special access attributes.
func
IPython.utils.text.dedent(text:str) -> strEquivalent of textwrap.dedent that ignores unindented first line.
func
IPython.utils.text.format_screen(strng:str) -> strFormat a string for screen printing.
func
IPython.utils.text.indent(instr:str, nspaces:int=4, ntabs:int=0, flatten:bool=False) -> strIndent a string a given number of spaces or tabstops.
func
IPython.utils.text.marquee(txt:str='', width:int=78, mark:str='*') -> strReturn the input string centered in a 'marquee'.
func
IPython.utils.text.strip_email_quotes(text:str) -> strStrip leading email quotation characters ('>').
func
IPython.utils.tokenutil.generate_tokens(readline:Callable) -> Generator[TokenInfo]wrap generate_tkens to catch EOF errors
func
IPython.utils.tokenutil.token_at_cursor(cell:str, cursor_pos:int=0) -> strGet the token at a given cursor Used for introspection.
class
setupbase.MyBuildPySubclass to write commit data into installation tree
func
setupbase.find_data_files()Find IPython's data_files.
About this data
These signatures were extracted from the public source of ipython/ipython
using Python's ast module. Argument names, default values,
type annotations and return types are taken verbatim from the code.
Implementation bodies are never stored. See
how it works for details.