We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 0d28945 + 60a02df commit 5db6db7Copy full SHA for 5db6db7
notebook/static/notebook/js/codecell.js
@@ -335,11 +335,13 @@ define([
335
this.render();
336
this.events.trigger('execute.CodeCell', {cell: this});
337
var that = this;
338
- this.events.on('finished_iopub.Kernel', function (evt, data) {
+ function handleFinished(evt, data) {
339
if (that.kernel.id === data.kernel.id && that.last_msg_id === data.msg_id) {
340
- that.events.trigger('finished_execute.CodeCell', {cell: that});
341
- }
342
- });
+ that.events.trigger('finished_execute.CodeCell', {cell: that});
+ that.events.off('finished_iopub.Kernel', handleFinished);
+ }
343
344
+ this.events.on('finished_iopub.Kernel', handleFinished);
345
};
346
347
/**
0 commit comments