These are chat archives for evhub/coconut

15th
Feb 2018
Ali Corbin
@alijc
Feb 15 2018 01:18
Is there a way to run the coconut interpreter so that it will accept normal (unix-style) copy and paste?
Elliott Indiran
@eindiran
Feb 15 2018 01:21
What do you mean unix-style copy and paste?
I am able to paste something into the interpreter using (ctrl + shift + v) which seems pretty standard on unix systems
Or are you tring to copy from the interpreter?
Ali Corbin
@alijc
Feb 15 2018 01:23
Select with mouse to copy, middle mouse button to paste.
Elliott Indiran
@eindiran
Feb 15 2018 01:25
interesting
If you copy something that way in a terminal, then open the coconut interpreter, you can still paste it. But I can't seem to get a cursor inside the terminal at all once coconut's interpreter has fired up
my terminal emulator straight-up greys out the option to paste something
I had never noticed that before
Elliott Indiran
@eindiran
Feb 15 2018 01:35
Were you using mouse-based highlight and paste for a particular reason or was it just a workflow you tried (and noticed the failure of)?
Ali Corbin
@alijc
Feb 15 2018 01:38
Yes. That's the most efficient way to copy and paste, and the way that I've been doing it for decades.
I'm dumping the interpreter. I'll be needing to use a text editor for writing real programs - I'll just switch to that today.
David Vo
@auscompgeek
Feb 15 2018 01:46
shift+click should work if your terminal is sane
Elliott Indiran
@eindiran
Feb 15 2018 01:47
shift+click works for whatever is already in the clipboard
David Vo
@auscompgeek
Feb 15 2018 01:48
I'm not sure what the coconut REPL is doing with prompt_toolkit... IPython doesn't exhibit the same behaviour
Elliott Indiran
@eindiran
Feb 15 2018 01:48
the problem is that when the interpeter is running, it appears to eat the cursor, making it impossible to get the highlight then paste flow @alijc istalking about
David Vo
@auscompgeek
Feb 15 2018 01:48
shift+select works fine for me
Elliott Indiran
@eindiran
Feb 15 2018 01:49
Okay cool. That works for me too. Is that standard for prompt_toolkit?
David Vo
@auscompgeek
Feb 15 2018 01:49
no, as IPython doesn't do the same thing
I don't think there should be any reason the coconut REPL would want mouse events
Evan Hubinger
@evhub
Feb 15 2018 02:09
Hmmm... it does seem like Coconut must be doing something strange with prompt_toolkit. I'll try to compare to IPython and see if I can figure out what's up. In the meantime, you can pass --style none to disable prompt_toolkit entirely.
Evan Hubinger
@evhub
Feb 15 2018 02:35
@alijc @auscompgeek @eindiran Try pip install -U coconut-develop and let me know if it's better now.