mirror of
https://github.com/python/cpython.git
synced 2025-07-30 06:34:15 +00:00
[3.13] gh-118908: Fix completions after namespace change in REPL (GH-120370) (#120392)
(cherry picked from commit 02e74c3562
)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
This commit is contained in:
parent
8f5ce42f34
commit
10821ccf06
2 changed files with 12 additions and 5 deletions
|
@ -96,9 +96,9 @@ def run_multiline_interactive_console(
|
|||
console: code.InteractiveConsole | None = None,
|
||||
) -> None:
|
||||
from .readline import _setup
|
||||
_setup()
|
||||
|
||||
namespace = mainmodule.__dict__ if mainmodule else DEFAULT_NAMESPACE
|
||||
_setup(namespace)
|
||||
|
||||
if console is None:
|
||||
console = InteractiveColoredConsole(
|
||||
namespace, filename="<stdin>"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue