ptpython is an advanced, cross-platform Python REPL (Read-Eval-Print Loop) built on top of the prompt_toolkit library. It provides features like syntax highlighting, autocompletion, multiline editing, mouse support, and customizable key bindings (Emacs and Vi modes). Currently at version 3.0.32, it sees fairly frequent updates, often with several patch releases per month.
No compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Used to embed the ptpython REPL directly into a Python application or script. It's common to pass `globals()` and `locals()` to make current scope variables available.
Used to explicitly load a configuration file when embedding the REPL, as configuration files are otherwise ignored in embedded mode.
To start a `ptpython` shell, simply run `ptpython` in your terminal. To embed it in a Python script for debugging or interactive sessions, use `ptpython.repl.embed()`. You should pass `globals()` and `locals()` to `embed()` to make the current scope available inside the REPL.
Breaking-change detection hasn't run for this library yet.
CVE tracking and dependency tree are planned for a later release.
No traffic data recorded yet.