File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed
packages/jupyterlab-lsp/src/features/completion Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,10 @@ export class EnhancedKernelCompleterProvider extends KernelCompleterProvider {
93
93
94
94
const manager = this . options . connectionManager ;
95
95
const widget = context . widget as IDocumentWidget ;
96
+ if ( typeof widget . context === 'undefined' ) {
97
+ // there is no path for Console as it is not a DocumentWidget
98
+ return upstream ;
99
+ }
96
100
const adapter = manager . adapters . get ( widget . context . path ) ;
97
101
98
102
if ( ! adapter ) {
Original file line number Diff line number Diff line change @@ -301,6 +301,10 @@ export class CompletionProvider implements ICompletionProvider<CompletionItem> {
301
301
}
302
302
const manager = this . options . connectionManager ;
303
303
const widget = context . widget as IDocumentWidget ;
304
+ if ( typeof widget . context === 'undefined' ) {
305
+ // there is no path for Console as it is not a DocumentWidget
306
+ return false ;
307
+ }
304
308
const adapter = manager . adapters . get ( widget . context . path ) ;
305
309
if ( ! adapter ) {
306
310
return false ;
You can’t perform that action at this time.
0 commit comments