unstale

pypi / prompt-toolkit

prompt-toolkit

What changed in prompt-toolkit 1 to 3, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

15 breaking3 deprecations15 new APIs and options2 performance4 behavior and defaults14 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

prompt-toolkit 311 changes

Breaking changes 2

  • Adds support for Python 3.14 and 3.15 and sets the minimum Python version to 3.10.

    3.0.53release notes

  • Sets a missing minimum requirement for wcwidth.

    3.0.53release notes

New APIs and options 1

  • Allows specifying show_numbers in ChoiceInput.

    3.0.53release notes

Performance 1

Fixes and other changes 7

  • Treats OSError from add_reader as EOFError on macOS kqueue.

    3.0.53release notes

  • Updates return types to include None when a dialog shortcut is cancelled.

    3.0.53release notes

  • Handles surrogate pairs when storing strings in file history.

    3.0.53release notes

  • Updates the meta_dict type hint to match WordCompleter.

    3.0.53release notes

  • Fixes the behavior of get_word_before_cursor.

    3.0.53release notes

  • Handles ASCII decode errors when decoding terminal types in the telnet protocol.

    3.0.53release notes

  • Fixes the 6x6x6 color cube range and adds missing grayscale shades 232 and 254–255.

    3.0.53release notes

prompt-toolkit 142 changes

Breaking changes 13

  • The on_invalidate callback moved from CommandLineInterface to Application.

    1.0.0release notes

  • The default Buffer in Application now uses IGNORE; pass RETURN_DOCUMENT for the previous behavior.

    1.0.0release notes

  • An EventLoop instance is now always expected rather than created in __init__.

    1.0.0release notes

  • editing_mode is now a CommandLineInterface property, replacing the vi_mode parameter in KeyBindingManager.

    1.0.0release notes

  • The current buffer is no longer reset by default; pass reset_current_buffer=True to reset it.

    1.0.0release notes

  • Callback was renamed to Event, and events should now receive one argument: the sender.

    1.0.0release notes

  • Selection mode is entered only when the current buffer is not empty.

    1.0.0release notes

  • SelectedText now reverses highlighted colors by default; style Token.SelectedText to set fixed foreground and background.

    1.0.0release notes

  • The Vi < and > key bindings became operators.

    1.0.0release notes

  • Application loads Vi bindings by default when no registry is given.

    1.0.0release notes

  • Implemented Vi digraphs; ControlK now inserts a digraph.

    1.0.0release notes

  • Vi motions now handle inclusive and linewise motions properly; several motions were adjusted to match Vim behavior.

    1.0.0release notes

  • Bracket motions now find enclosing brackets rather than the next bracket, and text objects and motions use separate bindings.

    1.0.0release notes

Deprecations 3

  • Renamed MouseEventTypes to MouseEventType; the old name remains valid but is deprecated.

    1.0.0release notes

  • Renamed PipeInput.send to PipeInput.send_text; the old name remains as a deprecated alias.

    1.0.0release notes

  • ViStateFilter is deprecated; use the filters defined in prompt_toolkit.filters.

    1.0.0release notes

New APIs and options 14

Performance 1

  • Uses the bisect module instead of a custom binary search to improve performance.

    1.0.0release notes

Behavior and default changes 4

  • Menu space is reserved only when complete_while_typing=True or when completions are available to display.

    1.0.0release notes

  • Emacs key bindings now recognize ControlDelete.

    1.0.0release notes

  • A default token is now provided for SearchToolbar.

    1.0.0release notes

  • A default token is now provided for SystemToolbar.

    1.0.0release notes

Fixes and other changes 7