Message185986
The only reason that the IDLE shell is slow is due to the shell's text widget being configured to have wrap="char". If we manually wrapped the output then the shell responds very quickly to rendering really long strings.
The attached proof-of-concept patch (against 2.7 tip) implements manual wrapping. You can type "print('a' * 10**6)" and the shell responds almost instantly when using no-subprocess mode. (The RPC overhead becomes readily apparent when using a subprocess, introducing a large uninteruptable delay. That's another issue.)
I left text wrapping enabled in the shell since the user may be using a variable-spaced font. A possible compromise would be to increase the wrap_index to a large number, like 32768, before IDLE inserts a '\n' into the output. This would mimic the wrapping behavior of the original shell, but keep the shell responsive when you write a very long string to the output. |
|
Date |
User |
Action |
Args |
2013-04-04 00:47:44 | roger.serwy | set | recipients:
+ roger.serwy, rhettinger, terry.reedy, kbk, josiahcarlson, drhok, taleinat, ajaksu2, gpolo |
2013-04-04 00:47:44 | roger.serwy | set | messageid: <1365036464.04.0.243713358333.issue1442493@psf.upfronthosting.co.za> |
2013-04-04 00:47:43 | roger.serwy | link | issue1442493 messages |
2013-04-04 00:47:43 | roger.serwy | create | |
|