Show More
@@ -56,6 +56,7 b' class HistoryTrim(BaseIPythonApplication):' | |||
|
56 | 56 | |
|
57 | 57 | inputs.pop() # Remove the extra element we got to check the length. |
|
58 | 58 | inputs.reverse() |
|
59 | if inputs: | |
|
59 | 60 | first_session = inputs[0][0] |
|
60 | 61 | outputs = list(con.execute('SELECT session, line, output FROM ' |
|
61 | 62 | 'output_history WHERE session >= ?', (first_session,))) |
@@ -83,6 +84,7 b' class HistoryTrim(BaseIPythonApplication):' | |||
|
83 | 84 | new_db.commit() |
|
84 | 85 | |
|
85 | 86 | |
|
87 | if inputs: | |
|
86 | 88 | with new_db: |
|
87 | 89 | # Add the recent history into the new database. |
|
88 | 90 | new_db.executemany('insert into sessions values (?,?,?,?,?)', sessions) |
General Comments 0
You need to be logged in to leave comments.
Login now