You are viewing an older version (9.3.0). Go to latest (9.13.0)
{ } Raw JSON

bundles / IPython 9.3.0 / IPython / core / interactiveshell / InteractiveShell / set_custom_completer

function

IPython.core.interactiveshell:InteractiveShell.set_custom_completer

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

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