Show More
@@ -303,7 +303,7 b' class HistoryManager(Configurable):' | |||
|
303 | 303 | n = len(input_hist) |
|
304 | 304 | if start < 0: |
|
305 | 305 | start += n |
|
306 | if not stop: | |
|
306 | if not stop or (stop > n): | |
|
307 | 307 | stop = n |
|
308 | 308 | elif stop < 0: |
|
309 | 309 | stop += n |
@@ -39,6 +39,9 b' def test_history():' | |||
|
39 | 39 | |
|
40 | 40 | nt.assert_equal(ip.history_manager.input_hist_raw, [''] + hist) |
|
41 | 41 | |
|
42 | # Check whether specifying a range beyond the end of the current | |
|
43 | # session results in an error (gh-804) | |
|
44 | ip.magic('%hist 2-500') | |
|
42 | 45 | |
|
43 | 46 | # New session |
|
44 | 47 | ip.history_manager.reset() |
General Comments 0
You need to be logged in to leave comments.
Login now