From 3048c01175e93e0eaf45b16ffb0643d72b1ea0a3 Mon Sep 17 00:00:00 2001 From: MinRK Date: Fri, 26 Aug 2011 23:18:48 -0700 Subject: [PATCH] fix undefined 'session_id' member in kernel.js --- IPython/frontend/html/notebook/static/js/kernel.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/IPython/frontend/html/notebook/static/js/kernel.js b/IPython/frontend/html/notebook/static/js/kernel.js index 708b933237c..ef7ea0c4002 100644 --- a/IPython/frontend/html/notebook/static/js/kernel.js +++ b/IPython/frontend/html/notebook/static/js/kernel.js @@ -20,6 +20,10 @@ var IPython = (function (IPython) { this.shell_channel = null; this.iopub_channel = null; this.running = false; + + this.username = "username"; + this.session_id = utils.uuid(); + if (typeof(WebSocket) !== 'undefined') { this.WebSocket = WebSocket } else if (typeof(MozWebSocket) !== 'undefined') { @@ -34,8 +38,8 @@ var IPython = (function (IPython) { var msg = { header : { msg_id : utils.uuid(), - username : "username", - session: this.session_id, + username : this.username, + session : this.session_id, msg_type : msg_type }, content : content,