[issue3559] Pasted \n not same as typed \n
report at bugs.python.org
Mon Aug 16 01:06:36 CEST 2010
Cherniavsky Beni <cben at users.sf.net> added the comment:
There are 2 issues here:
(1) There should be a quick & obvious way to paste and run several statements.
(2) If a user types several statements and presses Enter, all should run. The current behavior is badly broken, and pasting is just one of the ways to trigger this. Splitting this into a new bug: http://bugs.python.org/issue9618
The original formulation of this bug seems to favor an xterm-like solution to (1): when you paste \n-terminated, run them immediately, as if each \n was an Enter press.
I think a more IDLEic [think "idillic" ;-)] approach to solving (1) is to solve (2): keep the behavior that pasting creates a multi-line block without executing anything, make Enter execute it all. Benefits:
- More intuitive to users that have never pasted multiple lines into a shell terminal.
- More sensible: why should Pasting execute anything?!
- Allows editing any of the statements before running.
- Keeps all statements together for Alt+P recalling.
If there is agreement on this, then this issue requires no action beyond solving issue 9618.
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list