From 11f0ca371b745aefe66ab4bc3befe27dc171165a Mon Sep 17 00:00:00 2001 From: Chris LaFreniere <40371649+chlafreniere@users.noreply.github.com> Date: Wed, 13 Mar 2019 20:04:46 -0700 Subject: [PATCH] Show running state in cell toolbar immediately when cell is run (#4484) --- src/sql/parts/notebook/models/cell.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sql/parts/notebook/models/cell.ts b/src/sql/parts/notebook/models/cell.ts index b0a3da64dd..75d60f4e59 100644 --- a/src/sql/parts/notebook/models/cell.ts +++ b/src/sql/parts/notebook/models/cell.ts @@ -212,12 +212,12 @@ export class CellModel implements ICellModel { // TODO update source based on editor component contents let content = this.source; if (content) { - this.fireExecutionStateChanged(); let future = await kernel.requestExecute({ code: content, stop_on_error: true }, false); this.setFuture(future as FutureInternal); + this.fireExecutionStateChanged(); // For now, await future completion. Later we should just track and handle cancellation based on model notifications let result: nb.IExecuteReplyMsg = await future.done; if (result && result.content) {