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

gh-118911: Trailing whitespace in a block shouldn't prevent the user from terminating the code block #119355

Merged
merged 8 commits into from
May 22, 2024
Prev Previous commit
Fix ReST syntax in blurb, reword a bit
  • Loading branch information
ambv committed May 22, 2024
commit 27ad76cb9d6827686b331126f1e9eb9713916e9e
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
To match IPython's behaviour, updated `maybe-accept`'s logic so that if the user hits enter twice, they are able to terminate the block even if there's trailing whitespace.
Also, trimming trailing whitespace in HistoricalReader so that when the user hits arrow up, the cursor is on the last functional line. This matches IPython's behavior.
In PyREPL, updated ``maybe-accept``'s logic so that if the user hits
:kbd:`Enter` twice, they are able to terminate the block even if there's
trailing whitespace. Also, now when the user hits arrow up, the cursor
is on the last functional line. This matches IPython's behavior.
Patch by Aya Elsayed.
Loading