##// END OF EJS Templates
Merge pull request #3493 from minrk/restart-dialog...
Brian E. Granger -
r11101:f93cd111 merge
parent child Browse files
Show More
@@ -123,6 +123,18 b' var IPython = (function (IPython) {'
123 var index = that.find_cell_index(data.cell);
123 var index = that.find_cell_index(data.cell);
124 that.select(index);
124 that.select(index);
125 });
125 });
126
127 $([IPython.events]).on('status_autorestarting.Kernel', function () {
128 IPython.dialog.modal({
129 title: "Kernel Restarting",
130 body: "The kernel appears to have died. It will restart automatically.",
131 buttons: {
132 OK : {
133 class : "btn-primary"
134 }
135 }
136 });
137 });
126
138
127
139
128 $(document).keydown(function (event) {
140 $(document).keydown(function (event) {
@@ -448,6 +448,11 b' var IPython = (function (IPython) {'
448 } else if (content.execution_state === 'idle') {
448 } else if (content.execution_state === 'idle') {
449 $([IPython.events]).trigger('status_idle.Kernel', {kernel: this});
449 $([IPython.events]).trigger('status_idle.Kernel', {kernel: this});
450 } else if (content.execution_state === 'restarting') {
450 } else if (content.execution_state === 'restarting') {
451 // autorestarting is distinct from restarting,
452 // in that it means the kernel died and the server is restarting it.
453 // status_restarting sets the notification widget,
454 // autorestart shows the more prominent dialog.
455 $([IPython.events]).trigger('status_autorestarting.Kernel', {kernel: this});
451 $([IPython.events]).trigger('status_restarting.Kernel', {kernel: this});
456 $([IPython.events]).trigger('status_restarting.Kernel', {kernel: this});
452 } else if (content.execution_state === 'dead') {
457 } else if (content.execution_state === 'dead') {
453 this.stop_channels();
458 this.stop_channels();
General Comments 0
You need to be logged in to leave comments. Login now