Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Code to 1.93.0 #6984

Merged
merged 6 commits into from
Sep 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .node-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
20.11.1
20.15.1
2 changes: 1 addition & 1 deletion lib/vscode
Submodule vscode updated 1109 files
24 changes: 13 additions & 11 deletions patches/base-path.diff
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Index: code-server/lib/vscode/src/vs/base/common/network.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/base/common/network.ts
+++ code-server/lib/vscode/src/vs/base/common/network.ts
@@ -212,7 +212,9 @@ class RemoteAuthoritiesImpl {
@@ -215,7 +215,9 @@ class RemoteAuthoritiesImpl {
return URI.from({
scheme: platform.isWeb ? this._preferredWebSchema : Schemas.vscodeRemoteResource,
authority: `${host}:${port}`,
Expand Down Expand Up @@ -111,7 +111,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -269,16 +269,15 @@ export class WebClientServer {
@@ -272,16 +272,15 @@ export class WebClientServer {
return void res.end();
}

Expand All @@ -133,7 +133,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
);
if (!remoteAuthority) {
return serveError(req, res, 400, `Bad request.`);
@@ -305,8 +304,12 @@ export class WebClientServer {
@@ -308,8 +307,12 @@ export class WebClientServer {
scopes: [['user:email'], ['repo']]
} : undefined;

Expand All @@ -146,7 +146,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
embedderIdentifier: 'server-distro',
extensionsGallery: this._webExtensionResourceUrlTemplate && this._productService.extensionsGallery ? {
...this._productService.extensionsGallery,
@@ -335,7 +338,7 @@ export class WebClientServer {
@@ -338,7 +341,7 @@ export class WebClientServer {
folderUri: resolveWorkspaceURI(this._environmentService.args['default-folder']),
workspaceUri: resolveWorkspaceURI(this._environmentService.args['default-workspace']),
productConfiguration,
Expand All @@ -155,7 +155,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
};

const cookies = cookie.parse(req.headers.cookie || '');
@@ -352,9 +355,11 @@ export class WebClientServer {
@@ -355,9 +358,11 @@ export class WebClientServer {
const values: { [key: string]: string } = {
WORKBENCH_WEB_CONFIGURATION: asJSON(workbenchWebConfiguration),
WORKBENCH_AUTH_SESSION: authSessionInfo ? asJSON(authSessionInfo) : '',
Expand All @@ -168,17 +168,19 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
+ VS_BASE: vscodeBase,
};

if (useTestResolver) {
@@ -381,7 +386,7 @@ export class WebClientServer {
'default-src \'self\';',
// DEV ---------------------------------------------------------------------------------------
@@ -395,8 +400,8 @@ export class WebClientServer {
'img-src \'self\' https: data: blob:;',
'media-src \'self\';',
- `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' ${useTestResolver ? '' : `http://${remoteAuthority}`};`, // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html
+ `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' ${useTestResolver ? '' : ``};`, // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html
isESM ?
- `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} blob: 'nonce-1nline-m4p' ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' 'sha256-/r7rqQ+yrxt57sxLuQ6AMYcy/lUpvAIzHjIJt/OeLWU=' ${useTestResolver ? '' : `http://${remoteAuthority}`};` : // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.esm.html
- `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' ${useTestResolver ? '' : `http://${remoteAuthority}`};`, // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html
+ `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} blob: 'nonce-1nline-m4p' ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' 'sha256-/r7rqQ+yrxt57sxLuQ6AMYcy/lUpvAIzHjIJt/OeLWU=' ${useTestResolver ? '' : ``};` : // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.esm.html
+ `script-src 'self' 'unsafe-eval' ${WORKBENCH_NLS_BASE_URL ?? ''} ${this._getScriptCspHashes(data).join(' ')} '${webWorkerExtensionHostIframeScriptSHA}' ${useTestResolver ? '' : ``};`, // the sha is the same as in src/vs/workbench/services/extensions/worker/webWorkerExtensionHostIframe.html
'child-src \'self\';',
`frame-src 'self' https://*.vscode-cdn.net data:;`,
'worker-src \'self\' data: blob:;',
@@ -454,3 +459,70 @@ export class WebClientServer {
@@ -469,3 +474,70 @@ export class WebClientServer {
return void res.end(data);
}
}
Expand Down
2 changes: 1 addition & 1 deletion patches/disable-builtin-ext-update.diff
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
===================================================================
--- code-server.orig/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsWorkbenchService.ts
+++ code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsWorkbenchService.ts
@@ -299,6 +299,10 @@ export class Extension implements IExten
@@ -314,6 +314,10 @@ export class Extension implements IExten
if (this.type === ExtensionType.System && this.productService.quality === 'stable') {
return false;
}
Expand Down
12 changes: 6 additions & 6 deletions patches/display-language.diff
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Index: code-server/lib/vscode/src/vs/server/node/serverServices.ts
import { ProtocolConstants } from 'vs/base/parts/ipc/common/ipc.net';
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
import { ConfigurationService } from 'vs/platform/configuration/common/configurationService';
@@ -239,6 +239,9 @@ export async function setupServerService
@@ -243,6 +243,9 @@ export async function setupServerService
const channel = new ExtensionManagementChannel(extensionManagementService, (ctx: RemoteAgentConnectionContext) => getUriTransformer(ctx.remoteAuthority));
socketServer.registerChannel('extensions', channel);

Expand Down Expand Up @@ -160,24 +160,24 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
+import { getLocaleFromConfig, getBrowserNLSConfiguration } from 'vs/server/node/remoteLanguagePacks';
import { CharCode } from 'vs/base/common/charCode';
import { IExtensionManifest } from 'vs/platform/extensions/common/extensions';

@@ -97,6 +98,7 @@ export class WebClientServer {
import { isESM } from 'vs/base/common/amd';
@@ -99,6 +100,7 @@ export class WebClientServer {
private readonly _webExtensionResourceUrlTemplate: URI | undefined;

private readonly _staticRoute: string;
+ private readonly _serverRoot: string;
private readonly _callbackRoute: string;
private readonly _webExtensionRoute: string;

@@ -111,6 +113,7 @@ export class WebClientServer {
@@ -114,6 +116,7 @@ export class WebClientServer {
) {
this._webExtensionResourceUrlTemplate = this._productService.extensionsGallery?.resourceUrlTemplate ? URI.parse(this._productService.extensionsGallery.resourceUrlTemplate) : undefined;

+ this._serverRoot = serverRootPath;
this._staticRoute = `${serverRootPath}/static`;
this._callbackRoute = `${serverRootPath}/callback`;
this._webExtensionRoute = `/web-extension-resource`;
@@ -349,14 +352,22 @@ export class WebClientServer {
@@ -352,14 +355,22 @@ export class WebClientServer {
};

const cookies = cookie.parse(req.headers.cookie || '');
Expand Down Expand Up @@ -380,7 +380,7 @@ Index: code-server/lib/vscode/build/gulpfile.reh.js
===================================================================
--- code-server.orig/lib/vscode/build/gulpfile.reh.js
+++ code-server/lib/vscode/build/gulpfile.reh.js
@@ -56,6 +56,7 @@ const serverResources = [
@@ -59,6 +59,7 @@ const serverResourceIncludes = [

// NLS
'out-build/nls.messages.json',
Expand Down
10 changes: 5 additions & 5 deletions patches/external-file-actions.diff
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -333,6 +333,8 @@ export class WebClientServer {
@@ -336,6 +336,8 @@ export class WebClientServer {
serverBasePath: this._basePath,
webviewEndpoint: vscodeBase + this._staticRoute + '/out/vs/workbench/contrib/webview/browser/pre',
userDataPath: this._environmentService.userDataPath,
Expand Down Expand Up @@ -172,7 +172,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/files/browser/fileActions
import { IsWebContext } from 'vs/platform/contextkey/common/contextkeys';
import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation';
import { ThemeIcon } from 'vs/base/common/themables';
@@ -561,13 +561,16 @@ MenuRegistry.appendMenuItem(MenuId.Explo
@@ -566,13 +566,16 @@ MenuRegistry.appendMenuItem(MenuId.Explo
id: DOWNLOAD_COMMAND_ID,
title: DOWNLOAD_LABEL
},
Expand All @@ -196,7 +196,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/files/browser/fileActions
)
}));

@@ -579,6 +582,7 @@ MenuRegistry.appendMenuItem(MenuId.Explo
@@ -584,6 +587,7 @@ MenuRegistry.appendMenuItem(MenuId.Explo
title: UPLOAD_LABEL,
},
when: ContextKeyExpr.and(
Expand Down Expand Up @@ -289,7 +289,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/files/browser/views/explo

export class ExplorerDelegate implements IListVirtualDelegate<ExplorerItem> {

@@ -1001,7 +1002,8 @@ export class FileDragAndDrop implements
@@ -1005,7 +1006,8 @@ export class FileDragAndDrop implements
@IConfigurationService private configurationService: IConfigurationService,
@IInstantiationService private instantiationService: IInstantiationService,
@IWorkspaceEditingService private workspaceEditingService: IWorkspaceEditingService,
Expand All @@ -299,7 +299,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/files/browser/views/explo
) {
const updateDropEnablement = (e: IConfigurationChangeEvent | undefined) => {
if (!e || e.affectsConfiguration('explorer.enableDragAndDrop')) {
@@ -1226,15 +1228,17 @@ export class FileDragAndDrop implements
@@ -1230,15 +1232,17 @@ export class FileDragAndDrop implements

// External file DND (Import/Upload file)
if (data instanceof NativeDragAndDropData) {
Expand Down
2 changes: 1 addition & 1 deletion patches/getting-started.diff
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -337,6 +337,7 @@ export class WebClientServer {
@@ -340,6 +340,7 @@ export class WebClientServer {
userDataPath: this._environmentService.userDataPath,
isEnabledFileDownloads: !this._environmentService.args['disable-file-downloads'],
isEnabledFileUploads: !this._environmentService.args['disable-file-uploads'],
Expand Down
4 changes: 2 additions & 2 deletions patches/integration.diff
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -306,6 +306,7 @@ export class WebClientServer {
@@ -309,6 +309,7 @@ export class WebClientServer {
} : undefined;

const productConfiguration = {
Expand All @@ -276,7 +276,7 @@ Index: code-server/lib/vscode/src/server-main.js
===================================================================
--- code-server.orig/lib/vscode/src/server-main.js
+++ code-server/lib/vscode/src/server-main.js
@@ -336,4 +336,9 @@ function prompt(question) {
@@ -339,4 +339,9 @@ function prompt(question) {
});
}

Expand Down
2 changes: 1 addition & 1 deletion patches/local-storage.diff
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -328,6 +328,7 @@ export class WebClientServer {
@@ -331,6 +331,7 @@ export class WebClientServer {
remoteAuthority,
serverBasePath: this._basePath,
webviewEndpoint: vscodeBase + this._staticRoute + '/out/vs/workbench/contrib/webview/browser/pre',
Expand Down
2 changes: 1 addition & 1 deletion patches/logout.diff
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -311,6 +311,7 @@ export class WebClientServer {
@@ -314,6 +314,7 @@ export class WebClientServer {
codeServerVersion: this._productService.codeServerVersion,
rootEndpoint: base,
updateEndpoint: !this._environmentService.args['disable-update-check'] ? base + '/update/check' : undefined,
Expand Down
4 changes: 2 additions & 2 deletions patches/marketplace.diff
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -113,7 +113,7 @@ export class WebClientServer {
@@ -116,7 +116,7 @@ export class WebClientServer {

this._staticRoute = `${serverRootPath}/static`;
this._callbackRoute = `${serverRootPath}/callback`;
Expand All @@ -49,7 +49,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
}

/**
@@ -311,14 +311,7 @@ export class WebClientServer {
@@ -314,14 +314,7 @@ export class WebClientServer {
codeServerVersion: this._productService.codeServerVersion,
rootEndpoint: base,
embedderIdentifier: 'server-distro',
Expand Down
2 changes: 1 addition & 1 deletion patches/proposed-api.diff
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Index: code-server/lib/vscode/src/vs/workbench/services/extensions/common/extens
===================================================================
--- code-server.orig/lib/vscode/src/vs/workbench/services/extensions/common/extensions.ts
+++ code-server/lib/vscode/src/vs/workbench/services/extensions/common/extensions.ts
@@ -312,10 +312,7 @@ function extensionDescriptionArrayToMap(
@@ -313,10 +313,7 @@ function extensionDescriptionArrayToMap(
}

export function isProposedApiEnabled(extension: IExtensionDescription, proposal: ApiProposalName): boolean {
Expand Down
2 changes: 1 addition & 1 deletion patches/proxy-uri.diff
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -312,6 +312,7 @@ export class WebClientServer {
@@ -315,6 +315,7 @@ export class WebClientServer {
rootEndpoint: base,
updateEndpoint: !this._environmentService.args['disable-update-check'] ? base + '/update/check' : undefined,
logoutEndpoint: this._environmentService.args['auth'] && this._environmentService.args['auth'] !== "none" ? base + '/logout' : undefined,
Expand Down
2 changes: 1 addition & 1 deletion patches/service-worker.diff
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -313,6 +313,10 @@ export class WebClientServer {
@@ -316,6 +316,10 @@ export class WebClientServer {
updateEndpoint: !this._environmentService.args['disable-update-check'] ? base + '/update/check' : undefined,
logoutEndpoint: this._environmentService.args['auth'] && this._environmentService.args['auth'] !== "none" ? base + '/logout' : undefined,
proxyEndpointTemplate: process.env.VSCODE_PROXY_URI ?? base + '/proxy/{{port}}/',
Expand Down
6 changes: 3 additions & 3 deletions patches/sourcemaps.diff
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Index: code-server/lib/vscode/build/gulpfile.reh.js
===================================================================
--- code-server.orig/lib/vscode/build/gulpfile.reh.js
+++ code-server/lib/vscode/build/gulpfile.reh.js
@@ -243,8 +243,7 @@ function packageTask(type, platform, arc
@@ -288,8 +288,7 @@ function packageTask(type, platform, arc

const src = gulp.src(sourceFolderName + '/**', { base: '.' })
.pipe(rename(function (path) { path.dirname = path.dirname.replace(new RegExp('^' + sourceFolderName), 'out'); }))
Expand All @@ -20,7 +20,7 @@ Index: code-server/lib/vscode/build/gulpfile.reh.js

const workspaceExtensionPoints = ['debuggers', 'jsonValidation'];
const isUIExtension = (manifest) => {
@@ -283,9 +282,9 @@ function packageTask(type, platform, arc
@@ -328,9 +327,9 @@ function packageTask(type, platform, arc
.map(name => `.build/extensions/${name}/**`);

const extensions = gulp.src(extensionPaths, { base: '.build', dot: true });
Expand All @@ -32,7 +32,7 @@ Index: code-server/lib/vscode/build/gulpfile.reh.js

let version = packageJson.version;
const quality = product.quality;
@@ -459,7 +458,7 @@ function tweakProductForServerWeb(produc
@@ -504,7 +503,7 @@ function tweakProductForServerWeb(produc
const minifyTask = task.define(`minify-vscode-${type}`, task.series(
optimizeTask,
util.rimraf(`out-vscode-${type}-min`),
Expand Down
4 changes: 2 additions & 2 deletions patches/telemetry.diff
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Index: code-server/lib/vscode/src/vs/server/node/serverServices.ts
import { NullPolicyService } from 'vs/platform/policy/common/policy';
import { OneDataSystemAppender } from 'vs/platform/telemetry/node/1dsAppender';
import { LoggerService } from 'vs/platform/log/node/loggerService';
@@ -147,11 +149,23 @@ export async function setupServerService
@@ -151,11 +153,23 @@ export async function setupServerService
const requestService = new RequestService(configurationService, environmentService, logService, loggerService);
services.set(IRequestService, requestService);

Expand Down Expand Up @@ -134,7 +134,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -317,6 +317,8 @@ export class WebClientServer {
@@ -320,6 +320,8 @@ export class WebClientServer {
scope: vscodeBase + '/',
path: base + '/_static/out/browser/serviceWorker.js',
},
Expand Down
2 changes: 1 addition & 1 deletion patches/update-check.diff
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/server/node/webClientServer.ts
+++ code-server/lib/vscode/src/vs/server/node/webClientServer.ts
@@ -310,6 +310,7 @@ export class WebClientServer {
@@ -313,6 +313,7 @@ export class WebClientServer {
const productConfiguration = {
codeServerVersion: this._productService.codeServerVersion,
rootEndpoint: base,
Expand Down
Loading
Loading