File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -485,16 +485,17 @@ def do(self) -> None:
485485 from .pager import get_pager
486486 from site import gethistoryfile
487487
488+ # After the pager exits, the screen state is unknown (Unix may
489+ # restore via alternate screen, Windows shows pager output).
490+ # Clear and force a full redraw at the end for consistency.
491+ self .reader .console .clear ()
492+
488493 history = os .linesep .join (self .reader .history [:])
489494 self .reader .console .restore ()
490495 pager = get_pager ()
491496 pager (history , gethistoryfile ())
492497 self .reader .console .prepare ()
493498
494- # After the pager exits, the screen state is unknown (Unix may
495- # restore via alternate screen, Windows shows pager output).
496- # Clear and force a full redraw for consistency.
497- self .reader .console .clear ()
498499 self .reader .invalidate_full ()
499500
500501
Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ class UnixRefreshPlan:
155155
156156 After the user types ``e`` to complete ``name``::
157157
158- Before: >>> def greet(nam|):
158+ Before: >>> def greet(nam|):
159159 ▲
160160 LineUpdate here: insert_char "e"
161161
You can’t perform that action at this time.
0 commit comments