-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Julia REPL is slow when pasting a large block of code. #15787
Comments
This is on windows right? |
Yes. On Windows. |
Some related discussion: https://groups.google.com/forum/#!topic/julia-users/MoNy5BLIbSs and #7267 |
I've found that if you shrink the window to show just one line, windows cmd.exe is able to update the screen much faster |
Thank you. Additional info : it makes no difference if i use conemu or plain cmd.exe. |
conemu is also backed by cmd.exe, it just hides the window and copies the text from that window, as it appears, onto the text area you can see. |
I suppose Windows does not have bracketed paste mode. Is our heuristic to not redraw when inserting at the end not firing? |
we don't have a heuristic for that, since the printing logic keeps the count of how many lines have been printed |
I don't understand. We definitely used to have that heuristic. If the cursor is at the end of a non-full line, and we're inserting one character, there's no need to clear the screen. |
true, the heuristic (in edit_insert – LineEdit.jl:449) looks like it isn't supposed to be using this information (which is likely private to refresh_multi_line – LineEdit.jl:1034) |
Looks like somebody (probably me) just forgot that the position in the buffer is not the same as the column offset if there's multiple lines. Seems like that heuristic should be fixable. |
It does this on Mac in iTerm2 but not in Terminal.app. |
This should be significantly improved now with #17868. The original code is now pretty much instant to paste. Please reopen if there are still problems with the Windows pasting. |
OhMyREPL makes this worse (on Windows). |
Please, reopen! My REPL flickers heavily when I paste a large text. This is under Win10 and several Julia versions (at least 1.0.x, 1.3.0, and also 1.4.0). I posted this issue on Discourse to no avail. |
Are you using OhMyREPL? |
No. |
I just tried it on a MacOS 10.11.6 with Julia 1.3.0 and pasting works fine. The issue seems to be on Windows only. |
I suffered this problem on Emacs ansi-term for a long time.... Also, OhMyREPL makes it even worse. |
On a Windows machine? |
No, on a macbook pro. |
Edit. Pretty sure this is fixed on 1.6/master |
If i copy/paste a large block of code spanning multiple lines directly into the REPL then it is really slow. It looks like each code block is backspaced away and then completely retyped for every character in the pasted block of code.
To illustrate: try copy/pasting this piece of code into the REPL
https://raw.githubusercontent.com/jheinen/GR.jl/master/examples/mandel.jl
The text was updated successfully, but these errors were encountered: