From d5993476e1e997829463d1118313c6211e784b90 Mon Sep 17 00:00:00 2001 From: deepak1556 Date: Mon, 25 Oct 2021 23:02:44 +0900 Subject: [PATCH 01/14] chore: Update endgame notebooks --- .vscode/notebooks/endgame.github-issues | 2 +- .vscode/notebooks/my-endgame.github-issues | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.vscode/notebooks/endgame.github-issues b/.vscode/notebooks/endgame.github-issues index 803b8010852..73e8d473d45 100644 --- a/.vscode/notebooks/endgame.github-issues +++ b/.vscode/notebooks/endgame.github-issues @@ -7,7 +7,7 @@ { "kind": 2, "language": "github-issues", - "value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-dev repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server repo:microsoft/vscode-emmet-helper repo:microsoft/vscode-remotehub repo:microsoft/vscode-livepreview repo:microsoft/vscode-python repo:microsoft/vscode-jupyter repo:microsoft/vscode-jupyter-internal repo:microsoft/vscode-unpkg\n\n$MILESTONE=milestone:\"September 2021\"" + "value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-dev repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server repo:microsoft/vscode-emmet-helper repo:microsoft/vscode-remotehub repo:microsoft/vscode-livepreview repo:microsoft/vscode-python repo:microsoft/vscode-jupyter repo:microsoft/vscode-jupyter-internal repo:microsoft/vscode-unpkg\n\n$MILESTONE=milestone:\"October 2021\"" }, { "kind": 1, diff --git a/.vscode/notebooks/my-endgame.github-issues b/.vscode/notebooks/my-endgame.github-issues index d72c5862941..cbeea10596f 100644 --- a/.vscode/notebooks/my-endgame.github-issues +++ b/.vscode/notebooks/my-endgame.github-issues @@ -7,7 +7,7 @@ { "kind": 2, "language": "github-issues", - "value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-dev repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server repo:microsoft/vscode-remotehub repo:microsoft/vscode-emmet-helper repo:microsoft/vscode-livepreview repo:microsoft/vscode-python repo:microsoft/vscode-jupyter repo:microsoft/vscode-jupyter-internal\n\n$MILESTONE=milestone:\"September 2021\"\n\n$MINE=assignee:@me" + "value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-dev repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server repo:microsoft/vscode-remotehub repo:microsoft/vscode-emmet-helper repo:microsoft/vscode-livepreview repo:microsoft/vscode-python repo:microsoft/vscode-jupyter repo:microsoft/vscode-jupyter-internal\n\n$MILESTONE=milestone:\"October 2021\"\n\n$MINE=assignee:@me" }, { "kind": 1, From 2ea55a5cee6d1d2122109116020ccd8f995a35f9 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 25 Oct 2021 16:15:39 +0200 Subject: [PATCH 02/14] Remove the attribute `monaco-visible-view-zone` on view zones that are in folded regions (#121516) --- .../browser/viewParts/viewZones/viewZones.ts | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/browser/viewParts/viewZones/viewZones.ts b/src/vs/editor/browser/viewParts/viewZones/viewZones.ts index 7d6ae188521..149ae313653 100644 --- a/src/vs/editor/browser/viewParts/viewZones/viewZones.ts +++ b/src/vs/editor/browser/viewParts/viewZones/viewZones.ts @@ -18,12 +18,14 @@ import { IWhitespaceChangeAccessor, IEditorWhitespace } from 'vs/editor/common/v export interface IMyViewZone { whitespaceId: string; delegate: IViewZone; + isInHiddenArea: boolean; isVisible: boolean; domNode: FastDomNode; marginDomNode: FastDomNode | null; } interface IComputedViewZoneProps { + isInHiddenArea: boolean; afterViewLineNumber: number; heightInPx: number; minWidthInPx: number; @@ -86,6 +88,7 @@ export class ViewZones extends ViewPart { const id = keys[i]; const zone = this._zones[id]; const props = this._computeWhitespaceProps(zone.delegate); + zone.isInHiddenArea = props.isInHiddenArea; const oldWhitespace = oldWhitespaces.get(id); if (oldWhitespace && (oldWhitespace.afterLineNumber !== props.afterViewLineNumber || oldWhitespace.height !== props.heightInPx)) { whitespaceAccessor.changeOneWhitespace(id, props.afterViewLineNumber, props.heightInPx); @@ -146,6 +149,7 @@ export class ViewZones extends ViewPart { private _computeWhitespaceProps(zone: IViewZone): IComputedViewZoneProps { if (zone.afterLineNumber === 0) { return { + isInHiddenArea: false, afterViewLineNumber: 0, heightInPx: this._heightInPixels(zone), minWidthInPx: this._minWidthInPixels(zone) @@ -186,6 +190,7 @@ export class ViewZones extends ViewPart { const viewPosition = this._context.model.coordinatesConverter.convertModelPositionToViewPosition(zoneAfterModelPosition); const isVisible = this._context.model.coordinatesConverter.modelPositionIsVisible(zoneBeforeModelPosition); return { + isInHiddenArea: !isVisible, afterViewLineNumber: viewPosition.lineNumber, heightInPx: (isVisible ? this._heightInPixels(zone) : 0), minWidthInPx: this._minWidthInPixels(zone) @@ -234,6 +239,7 @@ export class ViewZones extends ViewPart { const myZone: IMyViewZone = { whitespaceId: whitespaceId, delegate: zone, + isInHiddenArea: props.isInHiddenArea, isVisible: false, domNode: createFastDomNode(zone.domNode), marginDomNode: zone.marginDomNode ? createFastDomNode(zone.marginDomNode) : null @@ -290,6 +296,7 @@ export class ViewZones extends ViewPart { if (this._zones.hasOwnProperty(id)) { const zone = this._zones[id]; const props = this._computeWhitespaceProps(zone.delegate); + zone.isInHiddenArea = props.isInHiddenArea; // const newOrdinal = this._getZoneOrdinal(zone.delegate); whitespaceAccessor.changeOneWhitespace(zone.whitespaceId, props.afterViewLineNumber, props.heightInPx); // TODO@Alex: change `newOrdinal` too @@ -356,8 +363,11 @@ export class ViewZones extends ViewPart { const visibleZones: { [id: string]: IViewWhitespaceViewportData; } = {}; let hasVisibleZone = false; - for (let i = 0, len = visibleWhitespaces.length; i < len; i++) { - visibleZones[visibleWhitespaces[i].id] = visibleWhitespaces[i]; + for (const visibleWhitespace of visibleWhitespaces) { + if (this._zones[visibleWhitespace.id].isInHiddenArea) { + continue; + } + visibleZones[visibleWhitespace.id] = visibleWhitespace; hasVisibleZone = true; } From 910511b9bd942e7232031521d3cf60474abc0556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Moreno?= Date: Mon, 25 Oct 2021 16:16:25 +0200 Subject: [PATCH 03/14] connect nested grids absolute offsets fix #129120 --- .../base/browser/ui/centered/centeredViewLayout.ts | 14 +++++++------- src/vs/base/browser/ui/grid/grid.ts | 8 ++++---- src/vs/base/browser/ui/grid/gridview.ts | 6 +++--- src/vs/workbench/browser/part.ts | 2 +- src/vs/workbench/browser/parts/compositePart.ts | 4 ++-- .../workbench/browser/parts/editor/editorPart.ts | 14 +++++++------- src/vs/workbench/browser/parts/panel/panelPart.ts | 8 ++++---- .../workbench/browser/parts/sidebar/sidebarPart.ts | 4 ++-- .../browser/parts/statusbar/statusbarPart.ts | 4 ++-- .../test/browser/workbenchTestServices.ts | 2 +- 10 files changed, 33 insertions(+), 33 deletions(-) diff --git a/src/vs/base/browser/ui/centered/centeredViewLayout.ts b/src/vs/base/browser/ui/centered/centeredViewLayout.ts index 1b77cd8f09f..29e72ce7684 100644 --- a/src/vs/base/browser/ui/centered/centeredViewLayout.ts +++ b/src/vs/base/browser/ui/centered/centeredViewLayout.ts @@ -21,7 +21,7 @@ const GOLDEN_RATIO = { rightMarginRatio: 0.1909 }; -function createEmptyView(background: Color | undefined): ISplitViewView { +function createEmptyView(background: Color | undefined): ISplitViewView<{ top: number, left: number }> { const element = $('.centered-layout-margin'); element.style.height = '100%'; if (background) { @@ -37,13 +37,13 @@ function createEmptyView(background: Color | undefined): ISplitViewView { }; } -function toSplitViewView(view: IView, getHeight: () => number): ISplitViewView { +function toSplitViewView(view: IView, getHeight: () => number): ISplitViewView<{ top: number, left: number }> { return { element: view.element, get maximumSize() { return view.maximumWidth; }, get minimumSize() { return view.minimumWidth; }, onDidChange: Event.map(view.onDidChange, e => e && e.width), - layout: (size, offset) => view.layout(size, getHeight(), 0, offset) + layout: (size, offset, ctx) => view.layout(size, getHeight(), ctx?.top ?? 0, (ctx?.left ?? 0) + offset) }; } @@ -53,12 +53,12 @@ export interface ICenteredViewStyles extends ISplitViewStyles { export class CenteredViewLayout implements IDisposable { - private splitView?: SplitView; + private splitView?: SplitView<{ top: number, left: number }>; private width: number = 0; private height: number = 0; private style!: ICenteredViewStyles; private didLayout = false; - private emptyViews: ISplitViewView[] | undefined; + private emptyViews: ISplitViewView<{ top: number, left: number }>[] | undefined; private readonly splitViewDisposables = new DisposableStore(); constructor(private container: HTMLElement, private view: IView, public readonly state: CenteredViewState = { leftMarginRatio: GOLDEN_RATIO.leftMarginRatio, rightMarginRatio: GOLDEN_RATIO.rightMarginRatio }) { @@ -86,7 +86,7 @@ export class CenteredViewLayout implements IDisposable { this.splitView.orthogonalEndSash = boundarySashes.bottom; } - layout(width: number, height: number): void { + layout(width: number, height: number, top: number, left: number): void { this.width = width; this.height = height; if (this.splitView) { @@ -95,7 +95,7 @@ export class CenteredViewLayout implements IDisposable { this.resizeMargins(); } } else { - this.view.layout(width, height, 0, 0); + this.view.layout(width, height, top, left); } this.didLayout = true; } diff --git a/src/vs/base/browser/ui/grid/grid.ts b/src/vs/base/browser/ui/grid/grid.ts index 23dd6cf9e39..e1224e9b4c3 100644 --- a/src/vs/base/browser/ui/grid/grid.ts +++ b/src/vs/base/browser/ui/grid/grid.ts @@ -254,8 +254,8 @@ export class Grid extends Disposable { this.gridview.style(styles); } - layout(width: number, height: number): void { - this.gridview.layout(width, height); + layout(width: number, height: number, top: number = 0, left: number = 0): void { + this.gridview.layout(width, height, top, left); this.didLayout = true; } @@ -556,8 +556,8 @@ export class SerializableGrid extends Grid { }; } - override layout(width: number, height: number): void { - super.layout(width, height); + override layout(width: number, height: number, top: number = 0, left: number = 0): void { + super.layout(width, height, top, left); if (this.initialLayoutContext) { this.initialLayoutContext = false; diff --git a/src/vs/base/browser/ui/grid/gridview.ts b/src/vs/base/browser/ui/grid/gridview.ts index 9cdff77a0b2..ea9de1c345d 100644 --- a/src/vs/base/browser/ui/grid/gridview.ts +++ b/src/vs/base/browser/ui/grid/gridview.ts @@ -980,11 +980,11 @@ export class GridView implements IDisposable { this.root.style(styles); } - layout(width: number, height: number): void { + layout(width: number, height: number, top: number = 0, left: number = 0): void { this.firstLayoutController.isLayoutEnabled = true; - const [size, orthogonalSize] = this.root.orientation === Orientation.HORIZONTAL ? [height, width] : [width, height]; - this.root.layout(size, 0, { orthogonalSize, absoluteOffset: 0, absoluteOrthogonalOffset: 0, absoluteSize: size, absoluteOrthogonalSize: orthogonalSize }); + const [size, orthogonalSize, offset, orthogonalOffset] = this.root.orientation === Orientation.HORIZONTAL ? [height, width, top, left] : [width, height, left, top]; + this.root.layout(size, offset, { orthogonalSize, absoluteOffset: offset, absoluteOrthogonalOffset: orthogonalOffset, absoluteSize: size, absoluteOrthogonalSize: orthogonalSize }); } addView(view: IView, size: number | Sizing, location: number[]): void { diff --git a/src/vs/workbench/browser/part.ts b/src/vs/workbench/browser/part.ts index fd89c569033..1830fb9ee87 100644 --- a/src/vs/workbench/browser/part.ts +++ b/src/vs/workbench/browser/part.ts @@ -136,7 +136,7 @@ export abstract class Part extends Component implements ISerializableView { abstract minimumHeight: number; abstract maximumHeight: number; - layout(width: number, height: number): void { + layout(width: number, height: number, _top: number, _left: number): void { this._dimension = new Dimension(width, height); } diff --git a/src/vs/workbench/browser/parts/compositePart.ts b/src/vs/workbench/browser/parts/compositePart.ts index 5906a9ea9da..1965f960715 100644 --- a/src/vs/workbench/browser/parts/compositePart.ts +++ b/src/vs/workbench/browser/parts/compositePart.ts @@ -469,8 +469,8 @@ export abstract class CompositePart extends Part { return AnchorAlignment.RIGHT; } - override layout(width: number, height: number): void { - super.layout(width, height); + override layout(width: number, height: number, top: number, left: number): void { + super.layout(width, height, top, left); // Layout contents this.contentAreaSize = Dimension.lift(super.layoutContents(width, height).contentSize); diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index 890a0c93387..06f3a883d2b 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -71,9 +71,9 @@ class GridWidgetView implements IView { this._gridWidget = grid; } - layout(width: number, height: number): void { + layout(width: number, height: number, top: number, left: number): void { if (this.gridWidget) { - this.gridWidget.layout(width, height); + this.gridWidget.layout(width, height, top, left); } } @@ -443,7 +443,7 @@ export class EditorPart extends Part implements IEditorGroupsService, IEditorGro this.doCreateGridControlWithState(gridDescriptor, activeGroup.id, currentGroupViews); // Layout - this.doLayout(this._contentDimension); + this.doLayout(this._contentDimension, 0, 0); // Update container this.updateContainer(); @@ -1117,20 +1117,20 @@ export class EditorPart extends Part implements IEditorGroupsService, IEditorGro this.centeredLayoutWidget.boundarySashes = sashes; } - override layout(width: number, height: number): void { + override layout(width: number, height: number, top: number, left: number): void { // Layout contents const contentAreaSize = super.layoutContents(width, height).contentSize; // Layout editor container - this.doLayout(Dimension.lift(contentAreaSize)); + this.doLayout(Dimension.lift(contentAreaSize), top, left); } - private doLayout(dimension: Dimension): void { + private doLayout(dimension: Dimension, top: number, left: number): void { this._contentDimension = dimension; // Layout Grid - this.centeredLayoutWidget.layout(this._contentDimension.width, this._contentDimension.height); + this.centeredLayoutWidget.layout(this._contentDimension.width, this._contentDimension.height, top, left); // Event this._onDidLayout.fire(dimension); diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index a35c4457beb..0b2ff517030 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -596,7 +596,7 @@ export abstract class BasePanelPart extends CompositePart impleme this.layoutCompositeBar(); } - override layout(width: number, height: number): void { + override layout(width: number, height: number, top: number, left: number): void { if (!this.layoutService.isVisible(this.partId)) { return; } @@ -604,7 +604,7 @@ export abstract class BasePanelPart extends CompositePart impleme this.contentDimension = new Dimension(width, height); // Layout contents - super.layout(this.contentDimension.width, this.contentDimension.height); + super.layout(this.contentDimension.width, this.contentDimension.height, top, left); // Layout composite bar this.layoutCompositeBar(); @@ -897,7 +897,7 @@ export class PanelPart extends BasePanelPart { return super.getToolbarWidth() + (this.globalToolBar?.getItemsWidth() ?? 0); } - override layout(width: number, height: number): void { + override layout(width: number, height: number, top: number, left: number): void { let dimensions: Dimension; if (this.layoutService.getPanelPosition() === Position.RIGHT) { dimensions = new Dimension(width - 1, height); // Take into account the 1px border when layouting @@ -906,7 +906,7 @@ export class PanelPart extends BasePanelPart { } // Layout contents - super.layout(dimensions.width, dimensions.height); + super.layout(dimensions.width, dimensions.height, top, left); } private updateGlobalToolbarActions(): void { diff --git a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts index 9e8b3f45664..6a621b3b61b 100644 --- a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts +++ b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts @@ -204,12 +204,12 @@ export class SidebarPart extends CompositePart implements IPaneCo container.style.outlineColor = this.getColor(SIDE_BAR_DRAG_AND_DROP_BACKGROUND) ?? ''; } - override layout(width: number, height: number): void { + override layout(width: number, height: number, top: number, left: number): void { if (!this.layoutService.isVisible(Parts.SIDEBAR_PART)) { return; } - super.layout(width, height); + super.layout(width, height, top, left); } // Viewlet service diff --git a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts index dfb3b2fa64d..9c014a43da5 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts @@ -520,8 +520,8 @@ export class StatusbarPart extends Part implements IStatusbarService { this.styleElement.textContent = `.monaco-workbench .part.statusbar > .items-container > .statusbar-item.has-beak:before { border-bottom-color: ${backgroundColor}; }`; } - override layout(width: number, height: number): void { - super.layout(width, height); + override layout(width: number, height: number, top: number, left: number): void { + super.layout(width, height, top, left); super.layoutContents(width, height); } diff --git a/src/vs/workbench/test/browser/workbenchTestServices.ts b/src/vs/workbench/test/browser/workbenchTestServices.ts index d92f1f51a06..7732ead517e 100644 --- a/src/vs/workbench/test/browser/workbenchTestServices.ts +++ b/src/vs/workbench/test/browser/workbenchTestServices.ts @@ -1635,7 +1635,7 @@ export class TestEditorPart extends EditorPart { export async function createEditorPart(instantiationService: IInstantiationService, disposables: DisposableStore): Promise { const part = disposables.add(instantiationService.createInstance(TestEditorPart)); part.create(document.createElement('div')); - part.layout(1080, 800); + part.layout(1080, 800, 0, 0); await part.whenReady; From 286606327d43a9bfc9f7891c7a1d721b30d1808d Mon Sep 17 00:00:00 2001 From: Logan Ramos Date: Mon, 25 Oct 2021 10:27:27 -0400 Subject: [PATCH 04/14] Fix #135692 --- extensions/git/src/commands.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index 7194bd88817..e32b6cc553a 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -702,7 +702,7 @@ export class CommandCenter { const document = window.activeTextEditor?.document; // If the document doesn't match what we opened then don't attempt to select the range - if (document?.uri !== uri) { + if (document?.uri.toString() !== uri.toString()) { continue; } From f5f0b2bad448f423bc55330d32d13407d0b45e7f Mon Sep 17 00:00:00 2001 From: Daniel Imms <2193314+Tyriar@users.noreply.github.com> Date: Mon, 25 Oct 2021 07:32:48 -0700 Subject: [PATCH 05/14] Support ' surrounding validated links Fixes #134462 --- .../browser/links/terminalValidatedLocalLinkProvider.ts | 4 ++-- .../browser/links/terminalValidatedLocalLinkProvider.test.ts | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/contrib/terminal/browser/links/terminalValidatedLocalLinkProvider.ts b/src/vs/workbench/contrib/terminal/browser/links/terminalValidatedLocalLinkProvider.ts index 393a06911ac..aaa34fa1881 100644 --- a/src/vs/workbench/contrib/terminal/browser/links/terminalValidatedLocalLinkProvider.ts +++ b/src/vs/workbench/contrib/terminal/browser/links/terminalValidatedLocalLinkProvider.ts @@ -34,8 +34,8 @@ export const winLocalLinkClause = '((' + winPathPrefix + '|(' + winExcludedPathC /** As xterm reads from DOM, space in that case is nonbreaking char ASCII code - 160, replacing space with nonBreakningSpace or space ASCII code - 32. */ export const lineAndColumnClause = [ - '((\\S*)", line ((\\d+)( column (\\d+))?))', // "(file path)", line 45 [see #40468] - '((\\S*)",((\\d+)(:(\\d+))?))', // "(file path)",45 [see #78205] + '((\\S*)[\'"], line ((\\d+)( column (\\d+))?))', // "(file path)", line 45 [see #40468] + '((\\S*)[\'"],((\\d+)(:(\\d+))?))', // "(file path)",45 [see #78205] '((\\S*) on line ((\\d+)(, column (\\d+))?))', // (file path) on line 8, column 13 '((\\S*):line ((\\d+)(, column (\\d+))?))', // (file path):line 8, column 13 '(([^\\s\\(\\)]*)(\\s?[\\(\\[](\\d+)(,\\s?(\\d+))?)[\\)\\]])', // (file path)(45), (file path) (45), (file path)(45,18), (file path) (45,18), (file path)(45, 18), (file path) (45, 18), also with [] diff --git a/src/vs/workbench/contrib/terminal/test/browser/links/terminalValidatedLocalLinkProvider.test.ts b/src/vs/workbench/contrib/terminal/test/browser/links/terminalValidatedLocalLinkProvider.test.ts index c255a7246f4..ea781ccc72f 100644 --- a/src/vs/workbench/contrib/terminal/test/browser/links/terminalValidatedLocalLinkProvider.test.ts +++ b/src/vs/workbench/contrib/terminal/test/browser/links/terminalValidatedLocalLinkProvider.test.ts @@ -71,7 +71,8 @@ const supportedLinkFormats: LinkFormatInfo[] = [ { urlFormat: '{0} [{1},{2}]', line: '5', column: '3' }, { urlFormat: '{0}[{1}, {2}]', line: '5', column: '3' }, { urlFormat: '{0} [{1}, {2}]', line: '5', column: '3' }, - { urlFormat: '{0}",{1}', line: '5' } + { urlFormat: '{0}",{1}', line: '5' }, + { urlFormat: '{0}\',{1}', line: '5' } ]; suite('Workbench - TerminalValidatedLocalLinkProvider', () => { From 48eb908fd6a3ba9a2d7060e76297b55931395c09 Mon Sep 17 00:00:00 2001 From: Don Jayamanne Date: Mon, 25 Oct 2021 08:23:43 -0700 Subject: [PATCH 06/14] Categorize kernels in the notebook kernel picker (#135502) * Categorize kernels in the notebook kernel picker * rename property * address review comments * more changes * fix liner * address review comments --- src/vs/vscode.proposed.d.ts | 4 ++ .../api/browser/mainThreadNotebookKernels.ts | 6 +++ .../workbench/api/common/extHost.protocol.ts | 1 + .../api/common/extHostNotebookKernels.ts | 9 ++++ .../interactive/browser/interactiveEditor.ts | 2 +- .../editorStatusBar/editorStatusBar.ts | 42 +++++++++++++++---- .../notebook/browser/controller/apiActions.ts | 1 + .../browser/notebookEditorKernelManager.ts | 2 +- .../browser/notebookKernelServiceImpl.ts | 13 +++--- .../viewParts/notebookKernelActionViewItem.ts | 2 +- .../notebook/common/notebookKernelService.ts | 4 +- 11 files changed, 68 insertions(+), 18 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 4fae0a8b955..39129a134cf 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -1575,6 +1575,10 @@ declare module 'vscode' { } export interface NotebookController { + /** + * The human-readable label used to categorise controllers. + */ + kind?: string; // todo@API allow add, not remove readonly rendererScripts: NotebookRendererScript[]; diff --git a/src/vs/workbench/api/browser/mainThreadNotebookKernels.ts b/src/vs/workbench/api/browser/mainThreadNotebookKernels.ts index a2a2f03736f..f870f23ef07 100644 --- a/src/vs/workbench/api/browser/mainThreadNotebookKernels.ts +++ b/src/vs/workbench/api/browser/mainThreadNotebookKernels.ts @@ -33,6 +33,7 @@ abstract class MainThreadKernel implements INotebookKernel { label: string; description?: string; detail?: string; + kind?: string; supportedLanguages: string[]; implementsExecutionOrder: boolean; localResourceRoot: URI; @@ -54,6 +55,7 @@ abstract class MainThreadKernel implements INotebookKernel { this.label = data.label; this.description = data.description; this.detail = data.detail; + this.kind = data.kind; this.supportedLanguages = isNonEmptyArray(data.supportedLanguages) ? data.supportedLanguages : _modeService.getRegisteredModes(); this.implementsExecutionOrder = data.supportsExecutionOrder ?? false; this.localResourceRoot = URI.revive(data.extensionLocation); @@ -76,6 +78,10 @@ abstract class MainThreadKernel implements INotebookKernel { this.detail = data.detail; event.detail = true; } + if (data.kind !== undefined) { + this.kind = data.kind; + event.kind = true; + } if (data.supportedLanguages !== undefined) { this.supportedLanguages = isNonEmptyArray(data.supportedLanguages) ? data.supportedLanguages : this._modeService.getRegisteredModes(); event.supportedLanguages = true; diff --git a/src/vs/workbench/api/common/extHost.protocol.ts b/src/vs/workbench/api/common/extHost.protocol.ts index 4d16d0c94f3..28ba6c7b75f 100644 --- a/src/vs/workbench/api/common/extHost.protocol.ts +++ b/src/vs/workbench/api/common/extHost.protocol.ts @@ -908,6 +908,7 @@ export interface INotebookKernelDto2 { label: string; detail?: string; description?: string; + kind?: string; supportedLanguages?: string[]; supportsInterrupt?: boolean; supportsExecutionOrder?: boolean; diff --git a/src/vs/workbench/api/common/extHostNotebookKernels.ts b/src/vs/workbench/api/common/extHostNotebookKernels.ts index 6d3ad94a81d..91b9099a90b 100644 --- a/src/vs/workbench/api/common/extHostNotebookKernels.ts +++ b/src/vs/workbench/api/common/extHostNotebookKernels.ts @@ -166,6 +166,15 @@ export class ExtHostNotebookKernels implements ExtHostNotebookKernelsShape { data.description = value; _update(); }, + get kind() { + checkProposedApiEnabled(extension); + return data.kind ?? ''; + }, + set kind(value) { + checkProposedApiEnabled(extension); + data.kind = value; + _update(); + }, get supportedLanguages() { return data.supportedLanguages; }, diff --git a/src/vs/workbench/contrib/interactive/browser/interactiveEditor.ts b/src/vs/workbench/contrib/interactive/browser/interactiveEditor.ts index 5e46ea2db8a..9d43955f28d 100644 --- a/src/vs/workbench/contrib/interactive/browser/interactiveEditor.ts +++ b/src/vs/workbench/contrib/interactive/browser/interactiveEditor.ts @@ -483,7 +483,7 @@ export class InteractiveEditor extends EditorPane { } const info = this.#notebookKernelService.getMatchingKernel(notebook); - const selectedOrSuggested = info.selected ?? info.suggested; + const selectedOrSuggested = info.selected ?? info.suggestions[0]; if (selectedOrSuggested) { const language = selectedOrSuggested.supportedLanguages[0]; diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.ts b/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.ts index e48b8416bfd..5c296c28d06 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/editorStatusBar/editorStatusBar.ts @@ -3,9 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import { groupBy } from 'vs/base/common/arrays'; import { Disposable, DisposableStore, IDisposable, MutableDisposable } from 'vs/base/common/lifecycle'; import { Schemas } from 'vs/base/common/network'; -import { uppercaseFirstLetter } from 'vs/base/common/strings'; +import { compareIgnoreCase, uppercaseFirstLetter } from 'vs/base/common/strings'; import { HoverProviderRegistry } from 'vs/editor/common/modes'; import * as nls from 'vs/nls'; import { Action2, MenuId, registerAction2 } from 'vs/platform/actions/common/actions'; @@ -14,7 +15,7 @@ import { ExtensionIdentifier } from 'vs/platform/extensions/common/extensions'; import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ILabelService } from 'vs/platform/label/common/label'; import { ILogService } from 'vs/platform/log/common/log'; -import { IQuickInputButton, IQuickInputService, IQuickPickItem } from 'vs/platform/quickinput/common/quickInput'; +import { IQuickInputButton, IQuickInputService, IQuickPickItem, QuickPickInput } from 'vs/platform/quickinput/common/quickInput'; import { Registry } from 'vs/platform/registry/common/platform'; import { ThemeIcon } from 'vs/platform/theme/common/themeService'; import type { SelectKernelReturnArgs } from 'vs/workbench/api/common/extHostNotebookKernels'; @@ -128,7 +129,7 @@ registerAction2(class extends Action2 { } const notebook = editor.textModel; - const { selected, all } = notebookKernelService.getMatchingKernel(notebook); + const { selected, all, suggestions } = notebookKernelService.getMatchingKernel(notebook); if (selected && controllerId && selected.id === controllerId && ExtensionIdentifier.equals(selected.extension, extensionId)) { // current kernel is wanted kernel -> done @@ -156,7 +157,7 @@ registerAction2(class extends Action2 { iconClass: ThemeIcon.asClassName(configureKernelIcon), tooltip: nls.localize('notebook.promptKernel.setDefaultTooltip', "Set as default for '{0}' notebooks", editor.textModel.viewType) }; - const picks: (KernelPick | IQuickPickItem)[] = all.map(kernel => { + function toQuickPick(kernel: INotebookKernel) { const res = { kernel, picked: kernel.id === selected?.id, @@ -172,16 +173,38 @@ registerAction2(class extends Action2 { res.description = nls.localize('current2', "{0} - Currently Selected", res.description); } } - { return res; } - }); + return res; + } + const quickPickItems: QuickPickInput[] = []; if (!all.length) { - picks.push({ + quickPickItems.push({ id: 'install', label: nls.localize('installKernels', "Install kernels from the marketplace"), }); + } else { + // Always display suggested kernels on the top. + if (suggestions.length) { + quickPickItems.push({ + type: 'separator', + label: nls.localize('suggestedKernels', "Suggested") + }); + quickPickItems.push(...suggestions.map(toQuickPick)); + } + + // Next display all of the kernels grouped by categories or extensions. + // If we don't have a kind, always display those at the bottom. + const picks = all.filter(item => item !== selected && !suggestions.includes(item)).map(toQuickPick); + const kernelsPerCategory = groupBy(picks, (a, b) => compareIgnoreCase(a.kernel.kind || 'z', b.kernel.kind || 'z')); + kernelsPerCategory.forEach(items => { + quickPickItems.push({ + type: 'separator', + label: items[0].kernel.kind || nls.localize('otherKernelKinds', "Other") + }); + quickPickItems.push(...items); + }); } - const pick = await quickInputService.pick(picks, { + const pick = await quickInputService.pick(quickPickItems, { placeHolder: selected ? nls.localize('prompt.placeholder.change', "Change kernel for '{0}'", labelService.getUriLabel(notebook.uri, { relative: true })) : nls.localize('prompt.placeholder.select', "Select kernel for '{0}'", labelService.getUriLabel(notebook.uri, { relative: true })), @@ -323,7 +346,8 @@ export class KernelStatus extends Disposable implements IWorkbenchContribution { this._kernelInfoElement.clear(); - let { selected, suggested, all } = this._notebookKernelService.getMatchingKernel(notebook); + let { selected, suggestions, all } = this._notebookKernelService.getMatchingKernel(notebook); + const suggested = suggestions[0]; let isSuggested = false; if (all.length === 0) { diff --git a/src/vs/workbench/contrib/notebook/browser/controller/apiActions.ts b/src/vs/workbench/contrib/notebook/browser/controller/apiActions.ts index 04679968f31..f06cabc40c9 100644 --- a/src/vs/workbench/contrib/notebook/browser/controller/apiActions.ts +++ b/src/vs/workbench/contrib/notebook/browser/controller/apiActions.ts @@ -69,6 +69,7 @@ CommandsRegistry.registerCommand('_resolveNotebookKernels', async (accessor, arg return kernels.all.map(provider => ({ id: provider.id, label: provider.label, + kind: provider.kind, description: provider.description, detail: provider.detail, isPreferred: false, // todo@jrieken,@rebornix diff --git a/src/vs/workbench/contrib/notebook/browser/notebookEditorKernelManager.ts b/src/vs/workbench/contrib/notebook/browser/notebookEditorKernelManager.ts index 9191cc0ca4d..b398ff9852d 100644 --- a/src/vs/workbench/contrib/notebook/browser/notebookEditorKernelManager.ts +++ b/src/vs/workbench/contrib/notebook/browser/notebookEditorKernelManager.ts @@ -25,7 +25,7 @@ export class NotebookEditorKernelManager extends Disposable { getSelectedOrSuggestedKernel(notebook: INotebookTextModel): INotebookKernel | undefined { // returns SELECTED or the ONLY available kernel const info = this._notebookKernelService.getMatchingKernel(notebook); - return info.selected ?? info.suggested; + return info.selected ?? info.suggestions[0]; } async executeNotebookCells(notebook: INotebookTextModel, cells: Iterable): Promise { diff --git a/src/vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl.ts b/src/vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl.ts index e0071988e6a..02452f1149b 100644 --- a/src/vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl.ts +++ b/src/vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl.ts @@ -180,15 +180,18 @@ export class NotebookKernelService extends Disposable implements INotebookKernel } } - const all = kernels - .sort((a, b) => b.instanceAffinity - a.instanceAffinity || b.typeAffinity - a.typeAffinity || a.score - b.score || a.kernel.label.localeCompare(b.kernel.label)) - .map(obj => obj.kernel); + kernels + .sort((a, b) => b.instanceAffinity - a.instanceAffinity || b.typeAffinity - a.typeAffinity || a.score - b.score || a.kernel.label.localeCompare(b.kernel.label)); + const all = kernels.map(obj => obj.kernel); // bound kernel const selectedId = this._notebookBindings.get(NotebookTextModelLikeId.str(notebook)); const selected = selectedId ? this._kernels.get(selectedId)?.kernel : undefined; - - return { all, selected, suggested: all.length === 1 ? all[0] : undefined }; + const suggestions = kernels.filter(item => item.instanceAffinity > 1 && item.kernel !== selected).map(item => item.kernel); + if (!suggestions.length && all.length) { + suggestions.push(all[0]); + } + return { all, selected, suggestions }; } // default kernel for notebookType diff --git a/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelActionViewItem.ts b/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelActionViewItem.ts index a6b5fc319e1..90f402d2316 100644 --- a/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelActionViewItem.ts +++ b/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelActionViewItem.ts @@ -72,7 +72,7 @@ export class NotebooKernelActionViewItem extends ActionViewItem { private _updateActionFromKernelInfo(info: INotebookKernelMatchResult): void { this._action.enabled = true; - const selectedOrSuggested = info.selected ?? info.suggested; + const selectedOrSuggested = info.selected ?? info.suggestions[0]; if (selectedOrSuggested) { // selected or suggested kernel this._action.label = selectedOrSuggested.label; diff --git a/src/vs/workbench/contrib/notebook/common/notebookKernelService.ts b/src/vs/workbench/contrib/notebook/common/notebookKernelService.ts index 235e0178ee5..cc406fe59cf 100644 --- a/src/vs/workbench/contrib/notebook/common/notebookKernelService.ts +++ b/src/vs/workbench/contrib/notebook/common/notebookKernelService.ts @@ -17,7 +17,7 @@ export interface ISelectedNotebooksChangeEvent { export interface INotebookKernelMatchResult { readonly selected: INotebookKernel | undefined; - readonly suggested: INotebookKernel | undefined; + readonly suggestions: INotebookKernel[]; readonly all: INotebookKernel[]; } @@ -26,6 +26,7 @@ export interface INotebookKernelChangeEvent { label?: true; description?: true; detail?: true; + kind?: true; supportedLanguages?: true; hasExecutionOrder?: true; } @@ -44,6 +45,7 @@ export interface INotebookKernel { label: string; description?: string; detail?: string; + kind?: string; supportedLanguages: string[]; implementsInterrupt?: boolean; implementsExecutionOrder?: boolean; From 974c28e69610f9bd0b4e1c0e92fc5df35b3a81bb Mon Sep 17 00:00:00 2001 From: Megan Rogge Date: Mon, 25 Oct 2021 15:34:36 +0000 Subject: [PATCH 07/14] fix terminal reconnection on reload, rt of #135481 --- src/vs/workbench/contrib/terminal/browser/terminalInstance.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/workbench/contrib/terminal/browser/terminalInstance.ts b/src/vs/workbench/contrib/terminal/browser/terminalInstance.ts index fb225d6b93f..7ffc02b2537 100644 --- a/src/vs/workbench/contrib/terminal/browser/terminalInstance.ts +++ b/src/vs/workbench/contrib/terminal/browser/terminalInstance.ts @@ -1100,7 +1100,6 @@ export class TerminalInstance extends Disposable implements ITerminalInstance { async detachFromProcess(): Promise { await this._processManager.detachFromProcess(); - this.dispose(); } forceRedraw(): void { From e3ce1fe0bba104f22b364e9995dbda6c11db1698 Mon Sep 17 00:00:00 2001 From: Megan Rogge Date: Mon, 25 Oct 2021 15:36:22 +0000 Subject: [PATCH 08/14] fix #133741 --- src/vs/workbench/contrib/terminal/browser/terminalService.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/contrib/terminal/browser/terminalService.ts b/src/vs/workbench/contrib/terminal/browser/terminalService.ts index 0c826d6a018..cb9898d7836 100644 --- a/src/vs/workbench/contrib/terminal/browser/terminalService.ts +++ b/src/vs/workbench/contrib/terminal/browser/terminalService.ts @@ -580,7 +580,7 @@ export class TerminalService implements ITerminalService { this._shutdownWindowCount = await this._nativeDelegate?.getWindowCount(); const shouldReviveProcesses = this._shouldReviveProcesses(reason); if (shouldReviveProcesses) { - await this._localTerminalService?.persistTerminalState(); + await this._primaryOffProcessTerminalService?.persistTerminalState(); } // Persist terminal _processes_ @@ -648,7 +648,7 @@ export class TerminalService implements ITerminalService { // Clear terminal layout info only when not persisting if (!this._shouldReviveProcesses(e.reason)) { - this._localTerminalService?.setTerminalLayoutInfo(undefined); + this._primaryOffProcessTerminalService?.setTerminalLayoutInfo(undefined); } } From 1466122aa839f26cfdfa1b63882bf8f7fd44a36f Mon Sep 17 00:00:00 2001 From: Harald Kirschner Date: Mon, 25 Oct 2021 08:46:16 -0700 Subject: [PATCH 09/14] Clean up for workspacetags (#135746) --- .../electron-sandbox/workspaceTagsService.ts | 20 +++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/contrib/tags/electron-sandbox/workspaceTagsService.ts b/src/vs/workbench/contrib/tags/electron-sandbox/workspaceTagsService.ts index 8e0747c6c89..6bad0f57970 100644 --- a/src/vs/workbench/contrib/tags/electron-sandbox/workspaceTagsService.ts +++ b/src/vs/workbench/contrib/tags/electron-sandbox/workspaceTagsService.ts @@ -38,6 +38,11 @@ const ModulesToLookFor = [ 'hapi', 'socket.io', 'restify', + 'next', + 'nuxt', + '@nestjs/core', + 'strapi', + 'gatsby', // JS frameworks 'react', 'react-native', @@ -48,6 +53,7 @@ const ModulesToLookFor = [ '@ionic', 'vue', 'tns-core-modules', + '@nativescript/core', 'electron', // Other interesting packages 'aws-sdk', @@ -297,6 +303,8 @@ export class WorkspaceTagsService implements IWorkspaceTagsService { "workspace.grunt" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.gulp" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.jake" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.devcontainer" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.docker" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.tsconfig" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.jsconfig" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.config.xml" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, @@ -311,6 +319,11 @@ export class WorkspaceTagsService implements IWorkspaceTagsService { "workspace.npm.hapi" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.npm.socket.io" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.npm.restify" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.npm.next" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.npm.nuxt" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.npm.@nestjs/core" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.npm.strapi" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, + "workspace.npm.gatsby" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.npm.rnpm-plugin-windows" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.npm.react" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, "workspace.npm.@angular/core" : { "classification": "SystemMetaData", "purpose": "FeatureInsight", "isMeasurement": true }, @@ -566,6 +579,8 @@ export class WorkspaceTagsService implements IWorkspaceTagsService { tags['workspace.grunt'] = nameSet.has('gruntfile.js'); tags['workspace.gulp'] = nameSet.has('gulpfile.js'); tags['workspace.jake'] = nameSet.has('jakefile.js'); + tags['workspace.devcontainer'] = nameSet.has('devcontainer.json'); + tags['workspace.docker'] = nameSet.has('Dockerfile') || nameSet.has('docker-compose.yml'); tags['workspace.tsconfig'] = nameSet.has('tsconfig.json'); tags['workspace.jsconfig'] = nameSet.has('jsconfig.json'); @@ -696,9 +711,9 @@ export class WorkspaceTagsService implements IWorkspaceTagsService { let dependencies = Object.keys(packageJsonContents['dependencies'] || {}).concat(Object.keys(packageJsonContents['devDependencies'] || {})); for (let dependency of dependencies) { - if ('react-native' === dependency) { + if (dependency.startsWith('react-native')) { tags['workspace.reactNative'] = true; - } else if ('tns-core-modules' === dependency) { + } else if ('tns-core-modules' === dependency || '@nativescript/core' === dependency) { tags['workspace.nativescript'] = true; } else if (ModulesToLookFor.indexOf(dependency) > -1) { tags['workspace.npm.' + dependency] = true; @@ -755,6 +770,7 @@ export class WorkspaceTagsService implements IWorkspaceTagsService { // Ignore errors when resolving android }); }); + return Promise.all([...packageJsonPromises, ...requirementsTxtPromises, ...pipfilePromises, ...pomPromises, ...gradlePromises, ...androidPromises]).then(() => tags); }); } From c8be3bb422292f2026ecf3036ba453471847c511 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 25 Oct 2021 17:58:54 +0200 Subject: [PATCH 10/14] fine tune verified publisher changes --- .../workbench/contrib/extensions/browser/extensionEditor.ts | 5 +++-- .../contrib/extensions/browser/extensionsWidgets.ts | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/contrib/extensions/browser/extensionEditor.ts b/src/vs/workbench/contrib/extensions/browser/extensionEditor.ts index 39a6a25f2c0..72785b4124d 100644 --- a/src/vs/workbench/contrib/extensions/browser/extensionEditor.ts +++ b/src/vs/workbench/contrib/extensions/browser/extensionEditor.ts @@ -375,7 +375,7 @@ export class ExtensionEditor extends EditorPane { template.publisher.classList.toggle('clickable', !!extension.url); template.publisherDisplayName.textContent = extension.publisherDisplayName; template.verifiedPublisherIcon.style.display = extension.publisherDomain?.verified ? 'inherit' : 'none'; - template.publisher.title = extension.publisherDomain?.link ?? ''; + template.publisher.title = extension.publisherDomain?.link ? localize('publisher verified tooltip', "This publisher has verified ownership of {0}", URI.parse(extension.publisherDomain.link).authority) : ''; template.installCount.parentElement?.classList.toggle('hide', !extension.url); @@ -846,7 +846,8 @@ export class ExtensionEditor extends EditorPane { resources.push([localize('license', "License"), URI.parse(extension.licenseUrl)]); } if (extension.publisherDomain?.verified) { - resources.push([extension.publisherDisplayName, URI.parse(extension.publisherDomain.link)]); + const publisherDomainUri = URI.parse(extension.publisherDomain.link); + resources.push([publisherDomainUri.authority, publisherDomainUri]); } if (resources.length) { const resourcesContainer = append(container, $('.resources-container')); diff --git a/src/vs/workbench/contrib/extensions/browser/extensionsWidgets.ts b/src/vs/workbench/contrib/extensions/browser/extensionsWidgets.ts index 374aad72999..3180faa2127 100644 --- a/src/vs/workbench/contrib/extensions/browser/extensionsWidgets.ts +++ b/src/vs/workbench/contrib/extensions/browser/extensionsWidgets.ts @@ -425,7 +425,8 @@ export class ExtensionHoverWidget extends ExtensionWidget { if (this.extension.publisherDomain?.verified) { const bgColor = this.themeService.getColorTheme().getColor(extensionVerifiedPublisherIconColor); - markdown.appendMarkdown(`$(${verifiedPublisherIcon.id}) [${this.extension.publisherDomain.link.length > 50 ? `${this.extension.publisherDomain.link.substring(0, 50)}...` : this.extension.publisherDomain.link}](${this.extension.publisherDomain.link})`); + const publisherVerifiedTooltip = localize('publisher verified tooltip', "This publisher has verified ownership of {0}", `[${URI.parse(this.extension.publisherDomain.link).authority}](${this.extension.publisherDomain.link})`); + markdown.appendMarkdown(`$(${verifiedPublisherIcon.id}) ${publisherVerifiedTooltip}`); markdown.appendText(`\n`); } From 54ab46f01667f8e1a2f094c73890b24312cc4b44 Mon Sep 17 00:00:00 2001 From: Megan Rogge Date: Mon, 25 Oct 2021 11:01:25 -0700 Subject: [PATCH 11/14] fix #133687 --- src/vs/workbench/contrib/terminal/browser/terminalService.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/contrib/terminal/browser/terminalService.ts b/src/vs/workbench/contrib/terminal/browser/terminalService.ts index cb9898d7836..756b2d4a50b 100644 --- a/src/vs/workbench/contrib/terminal/browser/terminalService.ts +++ b/src/vs/workbench/contrib/terminal/browser/terminalService.ts @@ -1363,6 +1363,10 @@ export class TerminalService implements ITerminalService { } private _getSplitParent(location?: ITerminalLocationOptions): ITerminalInstance | undefined { + if (this._connectionState === TerminalConnectionState.Connecting && this.activeInstance) { + const group = this._terminalGroupService.getGroupForInstance(this.activeInstance); + return group?.terminalInstances[group.terminalInstances.length - 1]; + } if (location && typeof location === 'object' && 'parentTerminal' in location) { return location.parentTerminal; } else if (location && typeof location === 'object' && 'splitActiveTerminal' in location) { From 7fd7b8f6616776ce0dfea44eadab7e91bb4e4a6e Mon Sep 17 00:00:00 2001 From: Megan Rogge Date: Mon, 25 Oct 2021 11:02:56 -0700 Subject: [PATCH 12/14] fix #134820 --- src/vs/vscode.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 77abc5089bd..0b03428ebcd 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -8422,7 +8422,7 @@ declare module 'vscode' { /** * The detected default shell for the extension host, this is overridden by the - * `terminal.integrated.shell` setting for the extension host's platform. Note that in + * `terminal.integrated.defaultProfile` setting for the extension host's platform. Note that in * environments that do not support a shell the value is the empty string. */ export const shell: string; From 4d496f61bcb6e381d00db77b1a144c3092b4d91e Mon Sep 17 00:00:00 2001 From: Tyler Leonhardt Date: Mon, 25 Oct 2021 11:16:37 -0700 Subject: [PATCH 13/14] remove keytar fallback in keychain and add a ton more logging to microsoft auth. ref #133201 --- .../src/common/keychain.ts | 38 ------ .../github-authentication/src/github.ts | 2 +- .../microsoft-authentication/src/AADHelper.ts | 123 ++++++++++-------- .../microsoft-authentication/src/extension.ts | 2 - .../microsoft-authentication/src/keychain.ts | 47 +------ .../microsoft-authentication/src/logger.ts | 6 +- 6 files changed, 74 insertions(+), 144 deletions(-) diff --git a/extensions/github-authentication/src/common/keychain.ts b/extensions/github-authentication/src/common/keychain.ts index c52505f0646..760ae8f3f27 100644 --- a/extensions/github-authentication/src/common/keychain.ts +++ b/extensions/github-authentication/src/common/keychain.ts @@ -5,29 +5,12 @@ // keytar depends on a native module shipped in vscode, so this is // how we load it -import type * as keytarType from 'keytar'; import * as vscode from 'vscode'; import * as nls from 'vscode-nls'; import { Log } from './logger'; const localize = nls.loadMessageBundle(); -function getKeytar(): Keytar | undefined { - try { - return require('keytar'); - } catch (err) { - console.log(err); - } - - return undefined; -} - -export type Keytar = { - getPassword: typeof keytarType['getPassword']; - setPassword: typeof keytarType['setPassword']; - deletePassword: typeof keytarType['deletePassword']; -}; - export class Keychain { constructor( private readonly context: vscode.ExtensionContext, @@ -72,25 +55,4 @@ export class Keychain { return Promise.resolve(undefined); } } - - async tryMigrate(): Promise { - try { - const keytar = getKeytar(); - if (!keytar) { - throw new Error('keytar unavailable'); - } - - const oldValue = await keytar.getPassword(`${vscode.env.uriScheme}-github.login`, 'account'); - if (oldValue) { - this.Logger.trace('Attempting to migrate from keytar to secret store...'); - await this.setToken(oldValue); - await keytar.deletePassword(`${vscode.env.uriScheme}-github.login`, 'account'); - } - - return oldValue; - } catch (_) { - // Ignore - return Promise.resolve(undefined); - } - } } diff --git a/extensions/github-authentication/src/github.ts b/extensions/github-authentication/src/github.ts index eb9a9e27d25..7cee96962f4 100644 --- a/extensions/github-authentication/src/github.ts +++ b/extensions/github-authentication/src/github.ts @@ -117,7 +117,7 @@ export class GitHubAuthenticationProvider implements vscode.AuthenticationProvid let sessionData: SessionData[]; try { this._logger.info('Reading sessions from keychain...'); - const storedSessions = await this._keychain.getToken() || await this._keychain.tryMigrate(); + const storedSessions = await this._keychain.getToken(); if (!storedSessions) { return []; } diff --git a/extensions/microsoft-authentication/src/AADHelper.ts b/extensions/microsoft-authentication/src/AADHelper.ts index 10c73dba3f5..f4caacd2a15 100644 --- a/extensions/microsoft-authentication/src/AADHelper.ts +++ b/extensions/microsoft-authentication/src/AADHelper.ts @@ -100,7 +100,7 @@ export class AzureActiveDirectoryService { private _tokens: IToken[] = []; private _refreshTimeouts: Map = new Map(); private _uriHandler: UriEventHandler; - private _disposables: vscode.Disposable[] = []; + private _disposable: vscode.Disposable; // Used to keep track of current requests when not using the local server approach. private _pendingStates = new Map(); @@ -112,51 +112,59 @@ export class AzureActiveDirectoryService { constructor(private _context: vscode.ExtensionContext) { this._keychain = new Keychain(_context); this._uriHandler = new UriEventHandler(); - this._disposables.push(vscode.window.registerUriHandler(this._uriHandler)); + this._disposable = vscode.Disposable.from( + vscode.window.registerUriHandler(this._uriHandler), + this._context.secrets.onDidChange(() => this.checkForUpdates())); } public async initialize(): Promise { - const storedData = await this._keychain.getToken() || await this._keychain.tryMigrate(); - if (storedData) { - try { - const sessions = this.parseStoredData(storedData); - const refreshes = sessions.map(async session => { - if (!session.refreshToken) { - return Promise.resolve(); - } + Logger.info('Reading sessions from keychain...'); + const storedData = await this._keychain.getToken(); + if (!storedData) { + Logger.info('No stored sessions found.'); + return; + } + Logger.info('Got stored sessions!'); - try { - await this.refreshToken(session.refreshToken, session.scope, session.id); - } catch (e) { - if (e.message === REFRESH_NETWORK_FAILURE) { - const didSucceedOnRetry = await this.handleRefreshNetworkError(session.id, session.refreshToken, session.scope); - if (!didSucceedOnRetry) { - this._tokens.push({ - accessToken: undefined, - refreshToken: session.refreshToken, - account: { - label: session.account.label ?? session.account.displayName!, - id: session.account.id - }, - scope: session.scope, - sessionId: session.id - }); - this.pollForReconnect(session.id, session.refreshToken, session.scope); - } - } else { - await this.removeSession(session.id); + try { + const sessions = this.parseStoredData(storedData); + const refreshes = sessions.map(async session => { + Logger.trace(`Read the following session from the keychain with the following scopes: ${session.scope}`); + if (!session.refreshToken) { + Logger.trace(`Session with the following scopes does not have a refresh token so we will not try to refresh it: ${session.scope}`); + return Promise.resolve(); + } + + try { + await this.refreshToken(session.refreshToken, session.scope, session.id); + } catch (e) { + // If we aren't connected to the internet, then wait and try to refresh again later. + if (e.message === REFRESH_NETWORK_FAILURE) { + const didSucceedOnRetry = await this.handleRefreshNetworkError(session.id, session.refreshToken, session.scope); + if (!didSucceedOnRetry) { + this._tokens.push({ + accessToken: undefined, + refreshToken: session.refreshToken, + account: { + label: session.account.label ?? session.account.displayName!, + id: session.account.id + }, + scope: session.scope, + sessionId: session.id + }); + this.pollForReconnect(session.id, session.refreshToken, session.scope); } + } else { + await this.removeSession(session.id); } - }); + } + }); - await Promise.all(refreshes); - } catch (e) { - Logger.info('Failed to initialize stored data'); - await this.clearSessions(); - } + await Promise.all(refreshes); + } catch (e) { + Logger.error(`Failed to initialize stored data: ${e}`); + await this.clearSessions(); } - - this._disposables.push(this._context.secrets.onDidChange(() => this.checkForUpdates)); } private parseStoredData(data: string): IStoredSession[] { @@ -263,8 +271,8 @@ export class AzureActiveDirectoryService { private async resolveAccessAndIdTokens(token: IToken): Promise { if (token.accessToken && (!token.expiresAt || token.expiresAt > Date.now())) { token.expiresAt - ? Logger.info(`Token available from cache, expires in ${token.expiresAt - Date.now()} milliseconds`) - : Logger.info('Token available from cache'); + ? Logger.info(`Token available from cache (for scopes ${token.scope}), expires in ${token.expiresAt - Date.now()} milliseconds`) + : Logger.info('Token available from cache (for scopes ${token.scope})'); return Promise.resolve({ accessToken: token.accessToken, idToken: token.idToken @@ -272,7 +280,7 @@ export class AzureActiveDirectoryService { } try { - Logger.info('Token expired or unavailable, trying refresh'); + Logger.info(`Token expired or unavailable (for scopes ${token.scope}), trying refresh`); const refreshedToken = await this.refreshToken(token.refreshToken, token.scope, token.sessionId); if (refreshedToken.accessToken) { return { @@ -301,17 +309,21 @@ export class AzureActiveDirectoryService { } async getSessions(scopes?: string[]): Promise { + Logger.info(`Getting sessions for ${scopes?.join(',') ?? 'all scopes'}...`); if (!scopes) { - return this.sessions; + const sessions = await this.sessions; + Logger.info(`Got ${sessions.length} sessions for all scopes...`); + return sessions; } const orderedScopes = scopes.sort().join(' '); const matchingTokens = this._tokens.filter(token => token.scope === orderedScopes); + Logger.info(`Got ${matchingTokens.length} sessions for ${scopes?.join(',')}...`); return Promise.all(matchingTokens.map(token => this.convertToSession(token))); } public async createSession(scope: string): Promise { - Logger.info('Logging in...'); + Logger.info(`Logging in for the following scopes: ${scope}`); if (!scope.includes('offline_access')) { Logger.info('Warning: The \'offline_access\' scope was not included, so the generated token will not be able to be refreshed.'); } @@ -360,7 +372,7 @@ export class AzureActiveDirectoryService { } token = await this.exchangeCodeForToken(codeRes.code, codeVerifier, scope); this.setToken(token, scope); - Logger.info('Login successful'); + Logger.info(`Login successful for scopes: ${scope}`); res.writeHead(302, { Location: '/' }); const session = await this.convertToSession(token); return session; @@ -371,7 +383,7 @@ export class AzureActiveDirectoryService { res.end(); } } catch (e) { - Logger.error(e.message); + Logger.error(`Error creating session for scopes: ${scope} Error: ${e}`); // If the error was about starting the server, try directly hitting the login endpoint instead if (e.message === 'Error listening to server' || e.message === 'Closed' || e.message === 'Timeout waiting for port') { @@ -387,8 +399,7 @@ export class AzureActiveDirectoryService { } public dispose(): void { - this._disposables.forEach(disposable => disposable.dispose()); - this._disposables = []; + this._disposable.dispose(); } private getCallbackEnvironment(callbackUri: vscode.Uri): string { @@ -550,7 +561,7 @@ export class AzureActiveDirectoryService { } private async exchangeCodeForToken(code: string, codeVerifier: string, scope: string): Promise { - Logger.info('Exchanging login code for token'); + Logger.info(`Exchanging login code for token for scopes: ${scope}`); try { const postData = querystring.stringify({ grant_type: 'authorization_code', @@ -575,21 +586,21 @@ export class AzureActiveDirectoryService { }); if (result.ok) { - Logger.info('Exchanging login code for token success'); const json = await result.json(); + Logger.info(`Exchanging login code for token (for scopes: ${scope}) succeeded!`); return this.getTokenFromResponse(json, scope); } else { - Logger.error('Exchanging login code for token failed'); + Logger.error(`Exchanging login code for token (for scopes: ${scope}) failed: ${await result.text()}`); throw new Error('Unable to login.'); } } catch (e) { - Logger.error(e.message); + Logger.error(`Error exchanging code for token (for scopes ${scope}): ${e}`); throw e; } } private async refreshToken(refreshToken: string, scope: string, sessionId: string): Promise { - Logger.info('Refreshing token...'); + Logger.info(`Refreshing token for scopes: ${scope}`); const postData = querystring.stringify({ refresh_token: refreshToken, client_id: clientId, @@ -611,7 +622,7 @@ export class AzureActiveDirectoryService { body: postData }); } catch (e) { - Logger.error('Refreshing token failed'); + Logger.error(`Refreshing token failed (for scopes: ${scope}) Error: ${e}`); throw new Error(REFRESH_NETWORK_FAILURE); } @@ -620,14 +631,14 @@ export class AzureActiveDirectoryService { const json = await result.json(); const token = this.getTokenFromResponse(json, scope, sessionId); this.setToken(token, scope); - Logger.info('Token refresh success'); + Logger.info(`Token refresh success for scopes: ${token.scope}`); return token; } else { throw new Error('Bad request.'); } } catch (e) { vscode.window.showErrorMessage(localize('signOut', "You have been signed out because reading stored authentication information failed.")); - Logger.error(`Refreshing token failed: ${result.statusText}`); + Logger.error(`Refreshing token failed (for scopes: ${scope}): ${result.statusText}`); throw new Error('Refreshing token failed'); } } @@ -668,7 +679,7 @@ export class AzureActiveDirectoryService { private handleRefreshNetworkError(sessionId: string, refreshToken: string, scope: string, attempts: number = 1): Promise { return new Promise((resolve, _) => { if (attempts === 3) { - Logger.error('Token refresh failed after 3 attempts'); + Logger.error(`Token refresh (for scopes: ${scope}) failed after 3 attempts`); return resolve(false); } diff --git a/extensions/microsoft-authentication/src/extension.ts b/extensions/microsoft-authentication/src/extension.ts index c824f61700a..22ec1b9ad35 100644 --- a/extensions/microsoft-authentication/src/extension.ts +++ b/extensions/microsoft-authentication/src/extension.ts @@ -7,8 +7,6 @@ import * as vscode from 'vscode'; import { AzureActiveDirectoryService, onDidChangeSessions } from './AADHelper'; import TelemetryReporter from 'vscode-extension-telemetry'; -export const DEFAULT_SCOPES = 'https://management.core.windows.net/.default offline_access'; - export async function activate(context: vscode.ExtensionContext) { const { name, version, aiKey } = context.extension.packageJSON as { name: string, version: string, aiKey: string }; const telemetryReporter = new TelemetryReporter(name, version, aiKey); diff --git a/extensions/microsoft-authentication/src/keychain.ts b/extensions/microsoft-authentication/src/keychain.ts index 1a0001c117e..f9704892887 100644 --- a/extensions/microsoft-authentication/src/keychain.ts +++ b/extensions/microsoft-authentication/src/keychain.ts @@ -3,47 +3,17 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -// keytar depends on a native module shipped in vscode, so this is -// how we load it -import * as keytarType from 'keytar'; import * as vscode from 'vscode'; import Logger from './logger'; import * as nls from 'vscode-nls'; const localize = nls.loadMessageBundle(); -function getKeytar(): Keytar | undefined { - try { - return require('keytar'); - } catch (err) { - console.log(err); - } - - return undefined; -} - -export type Keytar = { - getPassword: typeof keytarType['getPassword']; - setPassword: typeof keytarType['setPassword']; - deletePassword: typeof keytarType['deletePassword']; -}; - -const OLD_SERVICE_ID = `${vscode.env.uriScheme}-microsoft.login`; const SERVICE_ID = `microsoft.login`; -const ACCOUNT_ID = 'account'; export class Keychain { - private keytar: Keytar; - - constructor(private context: vscode.ExtensionContext) { - const keytar = getKeytar(); - if (!keytar) { - throw new Error('System keychain unavailable'); - } - - this.keytar = keytar; - } + constructor(private context: vscode.ExtensionContext) { } async setToken(token: string): Promise { @@ -87,19 +57,4 @@ export class Keychain { return Promise.resolve(undefined); } } - - async tryMigrate(): Promise { - try { - const oldValue = await this.keytar.getPassword(OLD_SERVICE_ID, ACCOUNT_ID); - if (oldValue) { - await this.setToken(oldValue); - await this.keytar.deletePassword(OLD_SERVICE_ID, ACCOUNT_ID); - } - - return oldValue; - } catch (_) { - // Ignore - return Promise.resolve(null); - } - } } diff --git a/extensions/microsoft-authentication/src/logger.ts b/extensions/microsoft-authentication/src/logger.ts index b9ed27bd993..db142875255 100644 --- a/extensions/microsoft-authentication/src/logger.ts +++ b/extensions/microsoft-authentication/src/logger.ts @@ -5,7 +5,7 @@ import * as vscode from 'vscode'; -type LogLevel = 'Info' | 'Error'; +type LogLevel = 'Trace' | 'Info' | 'Error'; class Log { private output: vscode.OutputChannel; @@ -24,6 +24,10 @@ class Log { return data.toString(); } + public trace(message: string, data?: any): void { + this.logLevel('Trace', message, data); + } + public info(message: string, data?: any): void { this.logLevel('Info', message, data); } From f3a14f6514a9b9194bdda1a690daa51ed72a65b0 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Mon, 25 Oct 2021 20:20:41 +0200 Subject: [PATCH 14/14] [css/html/json] update services --- .../css-language-features/server/package.json | 2 +- .../css-language-features/server/yarn.lock | 8 ++++---- .../html-language-features/server/package.json | 4 ++-- .../html-language-features/server/yarn.lock | 16 ++++++++-------- .../json-language-features/server/package.json | 2 +- .../json-language-features/server/yarn.lock | 8 ++++---- 6 files changed, 20 insertions(+), 20 deletions(-) diff --git a/extensions/css-language-features/server/package.json b/extensions/css-language-features/server/package.json index 9ac98007eb4..0ad75a779bb 100644 --- a/extensions/css-language-features/server/package.json +++ b/extensions/css-language-features/server/package.json @@ -10,7 +10,7 @@ "main": "./out/node/cssServerMain", "browser": "./dist/browser/cssServerMain", "dependencies": { - "vscode-css-languageservice": "^5.1.7", + "vscode-css-languageservice": "^5.1.8", "vscode-languageserver": "^7.0.0", "vscode-uri": "^3.0.2" }, diff --git a/extensions/css-language-features/server/yarn.lock b/extensions/css-language-features/server/yarn.lock index ee85eb997a6..3ca64a8a544 100644 --- a/extensions/css-language-features/server/yarn.lock +++ b/extensions/css-language-features/server/yarn.lock @@ -12,10 +12,10 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-14.14.43.tgz#26bcbb0595b305400e8ceaf9a127a7f905ae49c8" integrity sha512-3pwDJjp1PWacPTpH0LcfhgjvurQvrZFBrC6xxjaUEZ7ifUtT32jtjPxEMMblpqd2Mvx+k8haqQJLQxolyGN/cQ== -vscode-css-languageservice@^5.1.7: - version "5.1.7" - resolved "https://registry.yarnpkg.com/vscode-css-languageservice/-/vscode-css-languageservice-5.1.7.tgz#ebbf803b03fde539bd683588cd2da6c4a61b90e2" - integrity sha512-h4oafcZaGFe2VtbNIlkZDmLEP0GQha3E5Ct2YMH4p/p9xYC8yWDNQ5CD+VF3UnSijKPSKmA+oc4cKjhJBowGKw== +vscode-css-languageservice@^5.1.8: + version "5.1.8" + resolved "https://registry.yarnpkg.com/vscode-css-languageservice/-/vscode-css-languageservice-5.1.8.tgz#36cb389788ffc2d5e6630ffc84e55ee38f8a2338" + integrity sha512-Si1sMykS8U/p8LYgLGPCfZD1YFT0AtvUJQp9XJGw64DZWhtwYo28G2l64USLS9ge4ZPMZpwdpOK7PfbVKfgiiA== dependencies: vscode-languageserver-textdocument "^1.0.1" vscode-languageserver-types "^3.16.0" diff --git a/extensions/html-language-features/server/package.json b/extensions/html-language-features/server/package.json index 9f221c46084..264cd1c2c25 100644 --- a/extensions/html-language-features/server/package.json +++ b/extensions/html-language-features/server/package.json @@ -9,8 +9,8 @@ }, "main": "./out/node/htmlServerMain", "dependencies": { - "vscode-css-languageservice": "^5.1.7", - "vscode-html-languageservice": "^4.1.0", + "vscode-css-languageservice": "^5.1.8", + "vscode-html-languageservice": "^4.1.1", "vscode-languageserver": "^7.0.0", "vscode-languageserver-textdocument": "^1.0.1", "vscode-nls": "^5.0.0", diff --git a/extensions/html-language-features/server/yarn.lock b/extensions/html-language-features/server/yarn.lock index 503ea97f545..a9398ce6d02 100644 --- a/extensions/html-language-features/server/yarn.lock +++ b/extensions/html-language-features/server/yarn.lock @@ -12,20 +12,20 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-14.14.43.tgz#26bcbb0595b305400e8ceaf9a127a7f905ae49c8" integrity sha512-3pwDJjp1PWacPTpH0LcfhgjvurQvrZFBrC6xxjaUEZ7ifUtT32jtjPxEMMblpqd2Mvx+k8haqQJLQxolyGN/cQ== -vscode-css-languageservice@^5.1.7: - version "5.1.7" - resolved "https://registry.yarnpkg.com/vscode-css-languageservice/-/vscode-css-languageservice-5.1.7.tgz#ebbf803b03fde539bd683588cd2da6c4a61b90e2" - integrity sha512-h4oafcZaGFe2VtbNIlkZDmLEP0GQha3E5Ct2YMH4p/p9xYC8yWDNQ5CD+VF3UnSijKPSKmA+oc4cKjhJBowGKw== +vscode-css-languageservice@^5.1.8: + version "5.1.8" + resolved "https://registry.yarnpkg.com/vscode-css-languageservice/-/vscode-css-languageservice-5.1.8.tgz#36cb389788ffc2d5e6630ffc84e55ee38f8a2338" + integrity sha512-Si1sMykS8U/p8LYgLGPCfZD1YFT0AtvUJQp9XJGw64DZWhtwYo28G2l64USLS9ge4ZPMZpwdpOK7PfbVKfgiiA== dependencies: vscode-languageserver-textdocument "^1.0.1" vscode-languageserver-types "^3.16.0" vscode-nls "^5.0.0" vscode-uri "^3.0.2" -vscode-html-languageservice@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/vscode-html-languageservice/-/vscode-html-languageservice-4.1.0.tgz#e1662f1ff3b623b910c54d3f4a2aad8f397e53d7" - integrity sha512-QQrEKfpfbeglD8Jcai4fQDQ7vOJrN6LyiOs47Y6qAxnhve+ervw1kP2UCt9ohHe/6teNWJDYTGxLDgs5iAvitw== +vscode-html-languageservice@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/vscode-html-languageservice/-/vscode-html-languageservice-4.1.1.tgz#93739c9f3d0c12c8249bad23f5005850c289ec38" + integrity sha512-rrDyCiOgMwOPgchpPGAeLzjYVVEW/Ror2/a1BWUEI3S9+NQhA9vj4SQkzmH6g2Bq9S9SV0OQeadD+xphOf1N3w== dependencies: vscode-languageserver-textdocument "^1.0.1" vscode-languageserver-types "^3.16.0" diff --git a/extensions/json-language-features/server/package.json b/extensions/json-language-features/server/package.json index 42ae2fb1502..cfbbe5e5abb 100644 --- a/extensions/json-language-features/server/package.json +++ b/extensions/json-language-features/server/package.json @@ -14,7 +14,7 @@ "dependencies": { "jsonc-parser": "^3.0.0", "request-light": "^0.5.4", - "vscode-json-languageservice": "^4.1.8", + "vscode-json-languageservice": "^4.1.9", "vscode-languageserver": "^7.0.0", "vscode-uri": "^3.0.2" }, diff --git a/extensions/json-language-features/server/yarn.lock b/extensions/json-language-features/server/yarn.lock index 9efb139a764..06fd41ef116 100644 --- a/extensions/json-language-features/server/yarn.lock +++ b/extensions/json-language-features/server/yarn.lock @@ -22,10 +22,10 @@ request-light@^0.5.4: resolved "https://registry.yarnpkg.com/request-light/-/request-light-0.5.4.tgz#497a98c6d8ae49536417a5e2d7f383b934f3e38c" integrity sha512-t3566CMweOFlUk7Y1DJMu5OrtpoZEb6aSTsLQVT3wtrIEJ5NhcY9G/Oqxvjllzl4a15zXfFlcr9q40LbLVQJqw== -vscode-json-languageservice@^4.1.8: - version "4.1.8" - resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-4.1.8.tgz#397a39238d496e3e08a544a8b93df2cd13347d0c" - integrity sha512-0vSpg6Xd9hfV+eZAaYN63xVVMOTmJ4GgHxXnkLCh+9RsQBkWKIghzLhW2B9ebfG+LQQg8uLtsQ2aUKjTgE+QOg== +vscode-json-languageservice@^4.1.9: + version "4.1.9" + resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-4.1.9.tgz#fb48edc69e37167c3cafd447c3fa898052d87b61" + integrity sha512-kxNHitUy2fCxmP6vAp0SRLrUSuecUYzzxlC+85cC3jJlFHWmvtCJOzikC+kcUnIdls9fQSB8n0yHs8Sl6taxJw== dependencies: jsonc-parser "^3.0.0" vscode-languageserver-textdocument "^1.0.1"