Skip to content

Commit

Permalink
Update dependencies, remove @proposed (#931)
Browse files Browse the repository at this point in the history
  • Loading branch information
dbaeumer committed May 10, 2022
1 parent db25e42 commit 7cec6fc
Show file tree
Hide file tree
Showing 28 changed files with 767 additions and 1,658 deletions.
14 changes: 7 additions & 7 deletions client-node-tests/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion client-node-tests/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"@types/minimatch": "^3.0.5",
"@types/sinon": "^10.0.2",
"@types/uuid": "^8.3.1",
"@types/vscode": "1.66.0",
"@types/vscode": "1.67.0",
"glob": "^7.1.7",
"sinon": "^11.1.2",
"uuid": "^8.3.2",
Expand Down
14 changes: 7 additions & 7 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"devDependencies": {
"@types/minimatch": "^3.0.5",
"@types/semver": "^7.3.8",
"@types/vscode": "1.66.0",
"@types/vscode": "1.67.0",
"shx": "^0.3.3"
},
"dependencies": {
Expand Down
4 changes: 2 additions & 2 deletions client/src/common/codeConverter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export interface Converter {
asPosition(value: code.Position): proto.Position;
asPosition(value: code.Position | undefined | null): proto.Position | undefined | null;

asPositions(value: code.Position[], token?: code.CancellationToken): Promise<proto.Position[]>;
asPositions(value: readonly code.Position[], token?: code.CancellationToken): Promise<proto.Position[]>;

asRange(value: null): null;
asRange(value: undefined): undefined;
Expand Down Expand Up @@ -415,7 +415,7 @@ export function createConverter(uriConverter?: URIConverter): Converter {
return { line: value.line > proto.uinteger.MAX_VALUE ? proto.uinteger.MAX_VALUE : value.line, character: value.character > proto.uinteger.MAX_VALUE ? proto.uinteger.MAX_VALUE : value.character };
}

function asPositions(value: code.Position[], token?: code.CancellationToken): Promise<proto.Position[]> {
function asPositions(value: readonly code.Position[], token?: code.CancellationToken): Promise<proto.Position[]> {
return async.map(value, (asPosition as (item: code.Position) => proto.Position), token);
}

Expand Down
1 change: 0 additions & 1 deletion client/src/common/diagnostic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* ------------------------------------------------------------------------------------------ */
/// <reference path="../../typings/vscode.proposed.tabs.d.ts" />

import * as minimatch from 'minimatch';

Expand Down
1 change: 0 additions & 1 deletion client/src/common/notebook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* ------------------------------------------------------------------------------------------ */
/// <reference path="../../typings/vscode.proposed.notebookDocumentEvents.d.ts" />

import * as vscode from 'vscode';
import * as minimatch from 'minimatch';
Expand Down
4 changes: 2 additions & 2 deletions client/src/common/selectionRange.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ import {
import { TextDocumentLanguageFeature, FeatureClient, ensure } from './features';

export interface ProvideSelectionRangeSignature {
(this: void, document: TextDocument, positions: VPosition[], token: CancellationToken): ProviderResult<VSelectionRange[]>;
(this: void, document: TextDocument, positions: readonly VPosition[], token: CancellationToken): ProviderResult<VSelectionRange[]>;
}

export interface SelectionRangeProviderMiddleware {
provideSelectionRanges?: (this: void, document: TextDocument, positions: VPosition[], token: CancellationToken, next: ProvideSelectionRangeSignature) => ProviderResult<VSelectionRange[]>;
provideSelectionRanges?: (this: void, document: TextDocument, positions: readonly VPosition[], token: CancellationToken, next: ProvideSelectionRangeSignature) => ProviderResult<VSelectionRange[]>;
}

export class SelectionRangeFeature extends TextDocumentLanguageFeature<boolean | SelectionRangeOptions, SelectionRangeRegistrationOptions, SelectionRangeProvider, SelectionRangeProviderMiddleware> {
Expand Down
1 change: 0 additions & 1 deletion client/src/common/typeHierarchy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ export type TypeHierarchySubtypesSignature = (this: void, item: VTypeHierarchyIt
* Type hierarchy middleware
*
* @since 3.17.0
* @proposed
*/
export type TypeHierarchyMiddleware = {
prepareTypeHierarchy?: (this: void, document: TextDocument, positions: VPosition, token: CancellationToken, next: PrepareTypeHierarchySignature) => ProviderResult<VTypeHierarchyItem[]>;
Expand Down
8 changes: 5 additions & 3 deletions client/src/node/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,14 +213,16 @@ export class LanguageClient extends BaseLanguageClient {
}

private checkProcessDied(childProcess: ChildProcess | undefined): void {
if (!childProcess) {
if (!childProcess || childProcess.pid === undefined) {
return;
}
setTimeout(() => {
// Test if the process is still alive. Throws an exception if not
try {
process.kill(childProcess.pid, <any>0);
terminate(childProcess);
if (childProcess.pid !== undefined) {
process.kill(childProcess.pid, <any>0);
terminate(childProcess as (ChildProcess & { pid: number }));
}
} catch (error) {
// All is fine.
}
Expand Down
2 changes: 1 addition & 1 deletion client/src/node/processes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { join } from 'path';
const isWindows = (process.platform === 'win32');
const isMacintosh = (process.platform === 'darwin');
const isLinux = (process.platform === 'linux');
export function terminate(process: ChildProcess, cwd?: string): boolean {
export function terminate(process: ChildProcess & { pid: number }, cwd?: string): boolean {
if (isWindows) {
try {
// This we run in Atom execFileSync is available.
Expand Down
110 changes: 0 additions & 110 deletions client/typings/vscode.proposed.notebookDocumentEvents.d.ts

This file was deleted.

Loading

0 comments on commit 7cec6fc

Please sign in to comment.