Skip to content

Commit

Permalink
use tracer
Browse files Browse the repository at this point in the history
  • Loading branch information
FullteaR committed Jan 5, 2025
1 parent fb18851 commit f15a92c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Lib/_pyrepl/reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@ def calc_screen(self) -> list[str]:
if self.last_refresh_cache.valid(self):
offset, num_common_lines = self.last_refresh_cache.get_cached_location(self)

trace("self.last_refresh_cache.screen = " + str(self.last_refresh_cache.screen))
screen = self.last_refresh_cache.screen
del screen[num_common_lines:]

Expand All @@ -348,7 +349,10 @@ def calc_screen(self) -> list[str]:

prompt_from_cache = (offset and self.buffer[offset - 1] != "\n")

trace("self.buffer = " + str(self.buffer))
trace("offset = " + str(offset))
lines = "".join(self.buffer[offset:]).split("\n")
trace("lines = " + str(lines))

cursor_found = False
lines_beyond_cursor = 0
Expand Down

0 comments on commit f15a92c

Please sign in to comment.