This is a development version (9.14.0.dev) and may be unstable. Go to latest (9.13.0)
{ } Raw JSON

bundles / IPython 9.14.0.dev / IPython / core / interactiveshell / InteractiveShell / set_custom_completer

function

IPython.core.interactiveshell:InteractiveShell.set_custom_completer

source: /IPython/core/interactiveshell.py :2390

Signature

def   set_custom_completer ( self completer pos = 0 )  →  None

Summary

Adds a new custom completer function.

Extended Summary

The position argument (defaults to 0) is the index in the completers list where you want the completer to be inserted.

completer should have the following signature

def completion(self: Completer, text: string) -> List[str]:
    raise NotImplementedError

It will be bound to the current Completer instance and pass some text and return a list with current completions to suggest to the user.

Aliases

  • IPython.InteractiveShell.set_custom_completer