Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The pyrepl cache doesn't play well with history #121499

Closed
pablogsal opened this issue Jul 8, 2024 · 2 comments
Closed

The pyrepl cache doesn't play well with history #121499

pablogsal opened this issue Jul 8, 2024 · 2 comments
Labels
topic-repl Related to the interactive shell type-bug An unexpected behavior, bug, or error

Comments

@pablogsal
Copy link
Member

pablogsal commented Jul 8, 2024

Type the following in the REPL:

>>> def foo():
...     x = 1
...     y = 2
...     z = 3
...
>>> def bar():
...     return 42
...

Now press up arrow 3 times to go to the foo function. The REPL shows:

>>> def bar():
...     x = 1
...     y = 2
...     z = 3

which is a weird mix between the two entries.

I have bisected this to 32a0fab

Linked PRs

@pablogsal pablogsal changed the title The pyrepl cache doesn't play well with historu The pyrepl cache doesn't play well with history Jul 8, 2024
@pablogsal
Copy link
Member Author

CC @godlygeek

@Eclips4 Eclips4 added topic-repl Related to the interactive shell type-bug An unexpected behavior, bug, or error labels Jul 8, 2024
pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 9, 2024
pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 9, 2024
pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 9, 2024
@picnixz
Copy link
Contributor

picnixz commented Jul 9, 2024

Could it be related to #120460?

pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 13, 2024
pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 13, 2024
pablogsal added a commit to pablogsal/cpython that referenced this issue Jul 13, 2024
ambv pushed a commit that referenced this issue Jul 13, 2024
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Jul 13, 2024
…GH-121531)

(cherry picked from commit 4b9e10d)

Co-authored-by: Pablo Galindo Salgado <[email protected]>
Signed-off-by: Pablo Galindo <[email protected]>
pablogsal added a commit that referenced this issue Jul 13, 2024
…1531) (#121679)

gh-121499: Fix multi-line history rendering in the REPL (GH-121531)
(cherry picked from commit 4b9e10d)

Signed-off-by: Pablo Galindo <[email protected]>
Co-authored-by: Pablo Galindo Salgado <[email protected]>
estyxx pushed a commit to estyxx/cpython that referenced this issue Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic-repl Related to the interactive shell type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

3 participants