remove createNotebookCellExecutionTask from NotebookKernel2 because exec-handler is called with executions

This commit is contained in:
Johannes Rieken
2021-04-08 15:25:31 +02:00
parent be198294e4
commit 015d5565b7
2 changed files with 4 additions and 7 deletions

View File

@@ -113,9 +113,6 @@ export class ExtHostNotebookKernels implements ExtHostNotebookKernelsShape {
data.supportsInterrupt = Boolean(value);
_update();
},
createNotebookCellExecutionTask(uri, index) {
return that._extHostNotebook.createNotebookCellExecution(uri, index, data.id)!;
},
dispose: () => {
isDisposed = true;
this._kernelData.delete(handle);
@@ -150,12 +147,15 @@ export class ExtHostNotebookKernels implements ExtHostNotebookKernelsShape {
const cells = document.notebookDocument.getCells(NotebookCellRange.to(range));
for (let cell of cells) {
const exec = this._extHostNotebook.createNotebookCellExecution(document.uri, cell.index, obj.id);
// todo@jrieken there should always be an exec-object
if (exec) {
execs.push(exec);
} else {
// todo@jrieken there should always be an exec-object
console.warn('could NOT create notebook cell execution task for: ' + cell.document.uri);
}
}
}
try {
obj.executeHandler(execs);
} catch (err) {