Skip to content

Conversation

@vtjnash
Copy link
Member

@vtjnash vtjnash commented Feb 5, 2021

When input is arriving too fast, delay computing and rendering the full
screen until a short delay after typing stops. In particular, during testing,
this helped allow pasting into Windows consoles run at near full speed
with less excessive screen tearing.

When input is arriving too fast, delay computing and rendering the full
screen until a short delay after typing stops.
@vtjnash vtjnash added the REPL Julia's REPL (Read Eval Print Loop) label Feb 5, 2021
@kshyatt
Copy link
Member

kshyatt commented Feb 6, 2021

Test failure here is a timeout

@vtjnash
Copy link
Member Author

vtjnash commented Feb 7, 2021

FWIW, the timeout is an ArgTools bug (#39544), and I'm currently trying to find a way to work around that, as it is depending on a posixism, but a seemingly fairly reasonable one.

@vtjnash vtjnash requested a review from Keno February 10, 2021 16:15
@Keno
Copy link
Member

Keno commented Mar 3, 2021

I'm not a huge fan of the REPL just kicking off time-based work since it makes things somewhat unpredictable. I don't suppose Windows tells us if there's any more characters coming? That said, this is probably fine, since we'll always call clear_input_area before leaving the REPL, so at least we won't be interrupting any actual output.

@vtjnash
Copy link
Member Author

vtjnash commented Mar 3, 2021

yeah, short of inverting this entirely to an MVC-style app, I tried to be careful here to complete the render if demanded

tells us if there's any more characters coming

We probably already have them in the read buffer, and we'll process them ASAP? But that is quite nearly what this PR is exactly doing: checking to see if more characters are about to arrive before pushing a more expensive re-render.

@vtjnash vtjnash merged commit 26d887e into master Mar 8, 2021
@vtjnash vtjnash deleted the jn/slow-repl branch March 8, 2021 19:17
ElOceanografo pushed a commit to ElOceanografo/julia that referenced this pull request May 4, 2021
When input is arriving too fast, delay computing and rendering the full
screen until a short delay after typing stops.
antoine-levitt pushed a commit to antoine-levitt/julia that referenced this pull request May 9, 2021
When input is arriving too fast, delay computing and rendering the full
screen until a short delay after typing stops.
@KristofferC
Copy link
Member

KristofferC commented Oct 9, 2025

In particular, during testing, this helped allow pasting into Windows consoles run at near full speed with less excessive screen tearing.

I wonder if this regressed because pasting a 1000 line function now takes ~40s on Windows (cmd.exe).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

REPL Julia's REPL (Read Eval Print Loop)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants