bhauman / rebel-readline

Terminal readline library for Clojure dialects
Eclipse Public License 1.0
684 stars 37 forks source link

Flush / double printing behavior #183

Open rrrnld opened 5 years ago

rrrnld commented 5 years ago

Hi,

I really enjoy rebel-readline, thanks for that. When playing around with it I found behavior that is not quite intuitive for me to understand. The behavior seems to occur when dealing with long output:

user=> (second snowcover-days)
("1951-01-01" 15.0 13.0 15.0 15.0 24.0 17.0 9.0 22.0 17.0 16.0 16.0 12.0 13.0 13.0 11.0 13.0 13.0 10.0 22.0 11.0 20.0 10.0 18.0 18.0 12.0 14.0 17.0 10.0 10.0 13.0 14.0 21.0 13.0 14.0 12.0 16.0 12.0 23.0 8.0 14.0 14.0 14.0 22.0 21.0 12.0 16.0 15.0 15.0 17.0 16.0 18.0 21.0 16.0 21.0 13.0 22.0 11.0 13.0 13.0 11.0 9.0 19.0 13.0 19.0 16.0 9.0 13.0 14.0 14.0 20.0 21.0 10.0 14.0 19.0 11.0 23.0 13.0 18.0 8.0 9.0 20.0 19.0 16.0 19.0 21.0 13.0 20.0 18.0 11.0 15.0 26.0 12.0 11.0 8.0 15.0 17.0 17.0 22.0 10.0 14.0 11.0 13.0 11.0 18.0 12.0 20.0 11.0 14.0 19.0 13.0 19.0 13.0 10.0 14.0 19.0 18.0 18.0 13.0 17.0 16.0 18.0 19.0 12.0 23.0 10.0 15.0 16.0 14.0 19.0 24.0 19.0 21.0 22.0 17.0 13.0 13.0 24.0 15.0 18.0 13.0 15.0 12.0 7.0 19.0 11.0 8.0 18.0 10.0 18.0 16.0 21.0 19.0 16.0 11.0 28.0 11.0 18.0 16.0 24.0 18.0 14.0 11.0 16.0 10.0 10.0 9.0 13.0 13.0 13.0 13.0 19.0 11.0 6.0 17.0 15.0 12.0 18.0 13.0 9.0 12.0 19.0 14.0 18.0 15.0 7.0 16.0 11.0 10.0 12.0 21.0 13.0 15.0 19.0 19.0 17.0 16.0 10.0 11.0 19.0 13.0 9.0 9.0 17.0 16.0 7.0 14.0 14.0 16.0 16.0 19.0 21.0 22.0 20.0 14.0 12.0 11.0 22.0 13.0 22.0 13.0 15.0 25.0 14.0 10.0 16.0 17.0 14.0 11.0 11.0 13.0 14.0 16.0 19.0 9.0 17.0 11.0 13.0 16.0 17.0 11.0 13.0 14.0 12.0 16.0 13.0 15.0 12.0 18.0 13.0 17.0 12.0 15.0 22.0 9.0 9.0 21.0 7.0 20.0 13.0 19.0 9.0 16.0 16.0 22.0 16.0 9.0 12.0 15.0 10.0 13.0 21.0 20.0 13.0 15.0 16.0 17.0 16.0 9.0 16.0 20.0 18.0 25.0 19.0 6.0 21.0 14.0 18.0 10.0 17.0 11.0 15.0 22.0 11.0 14.0 10.0 16.0 13.0 18.0 14.0 11.0 10.0 19.0 18.0 17.0 12.0 18.0 14.0 7.0 20.0 22.0 15.0 15.0 19.0 21.0 15.0 13.0 16.0 19.0 16.0 10.0 17.0 18.0 15.0 19.0 15.0 12.0 17.0 20.0 10.0 9.0 12.0 10.0 24.0 14.0 6.0 11.0 14.0 16.0 17.0 17.0 15.0 11.0 19.0 12.0 16.0 19.0 10.0 13.0 15.0 15.0 13.0 16.0 12.0 16.0 17.0 16.0 20.0 14.0 16.0 14.0 13.0 9.0 26.0 16.0 13.0 18.0 17.0 17.0 9.0 21.0 14.0 17.0 18.0 18.0 15.0 23.0 23.0 13.0 17.0 7.0 15.0 8.0 19.0 11.0 16.0 15.0 15.0 12.0 19.0 14.0 10.0 16.0 13.0 19.0 12.0 11.0 23.0 14.0 13.0 11.0 15.0 12.0 12.0 20.0 15.0 10.0 11.0 13.0 15("1951-01-01" 15.0 13.0 15.0 15.0 24.0 17.0 9.0 22.0 17.0 16.0 16.0 12.0 13.0 13.0 11.0 13.0 13.0 10.0 22.0 11.0 20.0 10.0
6284.0

There should have been a line user=> (reduce + (rest (second snowcover-days))) in between but it got lost. Instead the previous output seems to be reprinted partially (you can see the timstamp appearing twice; it should be a list of timestamp + approx. 400 floats; the closing parenthesis are missing as well). I would have expected the second line to just display the reduced number. Is this something that I can fix on my side? My terminal is termite v14 on arch linux, TERM is xterm-termite.