You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are some regions of a virtual document representing notebook which are not to be annotated with diagnostics. These include:
(a) empty lines added between cells
(b) regions of transclusions, as defined by overrides
When the LSP code was merged into this repository, the overrides were not, and skipInspect remained in partial form - implementing (a) but not (b). How it used to be in the extension (link):
let{ lines, foreign_document_map, skip_inspect }=this.prepare_code_block(block,editor_shift);for(leti=0;i<lines.length;i++){this.virtual_lines.set(this.last_virtual_line+i,{skip_inspect: skip_inspect[i], # ←thislinewasmodifiededitor: ce_editor,// TODO this is incorrect, wont work if something was extractedsource_line: this.last_source_line+i});}
// TODO this is incorrect, wont work if something was extracted
sourceLine: this.lastSourceLine+i
});
}
Further, because virtualLines are protected it is not straightforward to access skipInspect.
Expected behavior
The logic allowing to pass skipInspect from prepareCodeBlock should be restored. virtualLines should stay protected, but skipInspect should be exposed, e.g.:
Description
There are some regions of a virtual document representing notebook which are not to be annotated with diagnostics. These include:
When the LSP code was merged into this repository, the overrides were not, and
skipInspect
remained in partial form - implementing (a) but not (b). How it used to be in the extension (link):How it is in core:
jupyterlab/packages/lsp/src/virtual/document.ts
Lines 632 to 639 in 7b1effc
Further, because
virtualLines
are protected it is not straightforward to accessskipInspect
.Expected behavior
The logic allowing to pass
skipInspect
fromprepareCodeBlock
should be restored.virtualLines
should stay protected, butskipInspect
should be exposed, e.g.:Alternatively this logic could be entirely removed, but it would be annoying having to re-implement this downstream.
Context
The text was updated successfully, but these errors were encountered: