##// END OF EJS Templates
Fix zmq request code for Python < 2.6.5
Thomas Kluyver -
Show More
@@ -309,8 +309,12 b' class Kernel(Configurable):'
309 logger.debug(msg)
309 logger.debug(msg)
310
310
311 def history_tail_request(self, ident, parent):
311 def history_tail_request(self, ident, parent):
312 # parent['content'] should contain keys "n", "raw" and "output"
312 # We need to pull these out, as passing **kwargs doesn't work with
313 hist = self.shell.history_manager.get_hist_tail(**parent['content'])
313 # unicode keys before Python 2.6.5.
314 n = parent['content']['n']
315 raw = parent['content']['raw']
316 output = parent['content']['output']
317 hist = self.shell.history_manager.get_hist_tail(n, raw=raw, output=output)
314 content = {'history' : list(hist)}
318 content = {'history' : list(hist)}
315 msg = self.session.send(self.reply_socket, 'history_tail_reply',
319 msg = self.session.send(self.reply_socket, 'history_tail_reply',
316 content, parent, ident)
320 content, parent, ident)
General Comments 0
You need to be logged in to leave comments. Login now