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

REPL history is corrupt after soft reset. #699

Closed
dlech opened this issue Aug 5, 2022 · 0 comments
Closed

REPL history is corrupt after soft reset. #699

dlech opened this issue Aug 5, 2022 · 0 comments
Assignees
Labels
bug Something isn't working software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) topic: MicroPython Issues related to the MicroPython programming language

Comments

@dlech
Copy link
Member

dlech commented Aug 5, 2022

Describe the bug
What is the problem?

REPL history is corrupt after soft reset.

To reproduce
Steps to reproduce the behavior:

  1. Connect to hub and start REPL in Pybricks Code
  2. Type in some code and press enter
  3. Press the up arrow key to retrieve the previous line from this history
  4. Press the stop button to do a soft reset
  5. Start the REPL again
  6. Press the up arrow key in the terminal
  7. Get garbage printed in the terminal

Expected behavior
What did you expect to happen instead?

Soft reset should either preserve history or reset history length back to zero.

Screenshots
There is a saying that a picture is worth a 1000 words. Screenshots really help to identify and solve problems.

image

@dlech dlech added bug Something isn't working software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) topic: MicroPython Issues related to the MicroPython programming language labels Aug 5, 2022
@dlech dlech changed the title [Bug] REPL history is corrupt after soft reset. Aug 9, 2022
@dlech dlech self-assigned this Aug 12, 2022
dlech added a commit to pybricks/pybricks-micropython that referenced this issue Aug 12, 2022
The readline history was not being cleared which lead to corrupt
contents after a soft reset of the MicroPython runtime.

Fixes: pybricks/support#699
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working software: pybricks-micropython Issues with Pybricks MicroPython firmware (or EV3 runtime) topic: MicroPython Issues related to the MicroPython programming language
Projects
None yet
Development

No branches or pull requests

1 participant