File tree Expand file tree Collapse file tree 4 files changed +6
-12
lines changed Expand file tree Collapse file tree 4 files changed +6
-12
lines changed Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ export class CellExecution {
122
122
public start ( kernelPromise : Promise < IKernel > , notebook : INotebook ) {
123
123
this . started = true ;
124
124
// Ensure we clear the cell state and trigger a change.
125
- clearCellForExecution ( this . editor , this . cell ) ;
125
+ clearCellForExecution ( this . cell ) ;
126
126
this . cell . metadata . runStartTime = new Date ( ) . getTime ( ) ;
127
127
this . stopWatch . reset ( ) ;
128
128
// Changes to metadata must be saved in ipynb, hence mark doc has dirty.
@@ -159,7 +159,7 @@ export class CellExecution {
159
159
private completedWithErrors ( error : Partial < Error > ) {
160
160
this . sendPerceivedCellExecute ( ) ;
161
161
this . cell . metadata . lastRunDuration = this . stopWatch . elapsedTime ;
162
- updateCellWithErrorStatus ( this . editor , this . cell , error ) ;
162
+ updateCellWithErrorStatus ( this . cell , error ) ;
163
163
this . contentProvider . notifyChangesToDocument ( this . cell . notebook ) ;
164
164
this . errorHandler . handleError ( ( error as unknown ) as Error ) . ignoreErrors ( ) ;
165
165
Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ export function handleUpdateDisplayDataMessage(
58
58
}
59
59
60
60
const vscCell = document . cells [ index ] ;
61
- updateCellOutput ( editor , vscCell , changedOutputs ) ;
61
+ updateCellOutput ( vscCell , changedOutputs ) ;
62
62
return true ;
63
63
} ) . length > 0
64
64
) ;
Original file line number Diff line number Diff line change @@ -13,8 +13,7 @@ import type {
13
13
NotebookCellData ,
14
14
NotebookCellMetadata ,
15
15
NotebookData ,
16
- NotebookDocument ,
17
- NotebookEditor
16
+ NotebookDocument
18
17
} from 'vscode-proposed' ;
19
18
import { NotebookCellRunState } from '../../../../../typings/vscode-proposed' ;
20
19
import { concatMultilineString , splitMultilineString } from '../../../../datascience-ui/common' ;
@@ -27,7 +26,6 @@ import { JupyterNotebookView } from '../constants';
27
26
// tslint:disable-next-line: no-var-requires no-require-imports
28
27
const vscodeNotebookEnums = require ( 'vscode' ) as typeof import ( 'vscode-proposed' ) ;
29
28
// tslint:disable-next-line: no-require-imports
30
- import { url } from 'inspector' ;
31
29
import cloneDeep = require( 'lodash/cloneDeep' ) ;
32
30
import { WorkspaceEdit } from 'vscode' ;
33
31
import { isUntitledFile } from '../../../common/utils/misc' ;
Original file line number Diff line number Diff line change @@ -98,12 +98,8 @@ export class VSCodeNotebookModel extends BaseNotebookModel {
98
98
}
99
99
public trust ( ) {
100
100
super . trust ( ) ;
101
- const editor =
102
- this . vscodeNotebook && this . document
103
- ? this . vscodeNotebook . notebookEditors . find ( ( e ) => e . document === this . document )
104
- : undefined ;
105
- if ( this . document && editor ) {
106
- updateVSCNotebookAfterTrustingNotebook ( editor , this . document , this . _cells ) ;
101
+ if ( this . document ) {
102
+ updateVSCNotebookAfterTrustingNotebook ( this . document , this . _cells ) ;
107
103
// We don't need old cells.
108
104
this . _cells = [ ] ;
109
105
}
You can’t perform that action at this time.
0 commit comments