Skip to content

Commit

Permalink
Revert "Update Patched VS Code version to 1.93.0 with patches applied"
Browse files Browse the repository at this point in the history
This reverts commit 391d548.
  • Loading branch information
aws-aijiacen committed Sep 12, 2024
1 parent 391d548 commit 328915b
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 29 deletions.
6 changes: 3 additions & 3 deletions patches/local-storage.diff
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ Index: sagemaker-code-editor/vscode/src/vs/server/node/webClientServer.ts
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/server/node/webClientServer.ts
+++ sagemaker-code-editor/vscode/src/vs/server/node/webClientServer.ts
@@ -330,6 +330,7 @@ export class WebClientServer {
@@ -332,6 +332,7 @@ export class WebClientServer {
const workbenchWebConfiguration = {
remoteAuthority,
serverBasePath: this._basePath,
webviewEndpoint: vscodeBase + this._staticRoute + '/out/vs/workbench/contrib/webview/browser/pre',
+ userDataPath: this._environmentService.userDataPath,
_wrapWebWorkerExtHostInIframe,
developmentOptions: { enableSmokeTestDriver: this._environmentService.args['enable-smoke-test-driver'] ? true : undefined, logLevel: this._logService.getLevel() },
Expand All @@ -32,7 +32,7 @@ Index: sagemaker-code-editor/vscode/src/vs/workbench/browser/web.api.ts
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/workbench/browser/web.api.ts
+++ sagemaker-code-editor/vscode/src/vs/workbench/browser/web.api.ts
@@ -298,6 +298,11 @@ export interface IWorkbenchConstructionO
@@ -276,6 +276,11 @@ export interface IWorkbenchConstructionO
*/
readonly configurationDefaults?: Record<string, any>;

Expand Down
22 changes: 12 additions & 10 deletions patches/sagemaker-idle-extension.patch
Original file line number Diff line number Diff line change
Expand Up @@ -269,10 +269,10 @@ Index: sagemaker-code-editor/vscode/build/gulpfile.extensions.js
===================================================================
--- sagemaker-code-editor.orig/vscode/build/gulpfile.extensions.js
+++ sagemaker-code-editor/vscode/build/gulpfile.extensions.js
@@ -59,6 +59,7 @@ const compilations = [
'extensions/references-view/tsconfig.json',
@@ -61,6 +61,7 @@ const compilations = [
'extensions/search-result/tsconfig.json',
'extensions/simple-browser/tsconfig.json',
'extensions/sagemaker-extension/tsconfig.json',
+ 'extensions/sagemaker-idle-extension/tsconfig.json',
'extensions/tunnel-forwarding/tsconfig.json',
'extensions/typescript-language-features/test-workspace/tsconfig.json',
Expand All @@ -281,10 +281,10 @@ Index: sagemaker-code-editor/vscode/build/npm/dirs.js
===================================================================
--- sagemaker-code-editor.orig/vscode/build/npm/dirs.js
+++ sagemaker-code-editor/vscode/build/npm/dirs.js
@@ -38,6 +38,7 @@ const dirs = [
'extensions/npm',
@@ -40,6 +40,7 @@ const dirs = [
'extensions/php-language-features',
'extensions/references-view',
'extensions/sagemaker-extension',
+ 'extensions/sagemaker-idle-extension',
'extensions/search-result',
'extensions/simple-browser',
Expand All @@ -296,28 +296,28 @@ Index: sagemaker-code-editor/vscode/src/vs/server/node/webClientServer.ts
@@ -4,6 +4,7 @@
*--------------------------------------------------------------------------------------------*/

import { createReadStream, promises } from 'fs';
import { createReadStream } from 'fs';
+import {readFile } from 'fs/promises';
import { Promises } from 'vs/base/node/pfs';
import * as path from 'path';
import * as http from 'http';
import * as url from 'url';
@@ -101,6 +102,7 @@ export class WebClientServer {
@@ -100,6 +101,7 @@ export class WebClientServer {
private readonly _staticRoute: string;
private readonly _callbackRoute: string;
private readonly _webExtensionRoute: string;
+ private readonly _idleRoute: string;

constructor(
private readonly _connectionToken: ServerConnectionToken,
@@ -117,6 +119,7 @@ export class WebClientServer {
@@ -115,6 +117,7 @@ export class WebClientServer {
this._staticRoute = `${serverRootPath}/static`;
this._callbackRoute = `${serverRootPath}/callback`;
this._webExtensionRoute = `${serverRootPath}/web-extension-resource`;
+ this._idleRoute = '/api/idle';
}

/**
@@ -134,6 +137,9 @@ export class WebClientServer {
@@ -132,6 +135,9 @@ export class WebClientServer {
if (pathname === this._basePath) {
return this._handleRoot(req, res, parsedUrl);
}
Expand All @@ -327,7 +327,7 @@ Index: sagemaker-code-editor/vscode/src/vs/server/node/webClientServer.ts
if (pathname === this._callbackRoute) {
// callback support
return this._handleCallback(res);
@@ -468,4 +474,25 @@ export class WebClientServer {
@@ -451,6 +457,27 @@ export class WebClientServer {
});
return void res.end(data);
}
Expand All @@ -353,3 +353,5 @@ Index: sagemaker-code-editor/vscode/src/vs/server/node/webClientServer.ts
+ }
+ }
}

/**
51 changes: 37 additions & 14 deletions patches/sagemaker-integration.diff
Original file line number Diff line number Diff line change
Expand Up @@ -69,24 +69,24 @@ Index: sagemaker-code-editor/vscode/src/vs/workbench/browser/web.main.ts
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/workbench/browser/web.main.ts
+++ sagemaker-code-editor/vscode/src/vs/workbench/browser/web.main.ts
@@ -96,6 +96,7 @@ import { ISecretStorageService } from 'v
@@ -95,6 +95,7 @@ import { TunnelSource } from 'vs/workbench/services/re
import { TunnelSource } from 'vs/workbench/services/remote/common/tunnelModel';
import { mainWindow } from 'vs/base/browser/window';
import { INotificationService, Severity } from 'vs/platform/notification/common/notification';
+import { SagemakerServerClient } from 'vs/workbench/browser/client';

export class BrowserMain extends Disposable {

@@ -131,6 +132,9 @@ export class BrowserMain extends Disposa
@@ -129,6 +130,9 @@ export class BrowserMain extends Disposable {

// Startup
const instantiationService = workbench.startup();
+
+ // Create instance of SagemakerServerClient
+ this._register(instantiationService.createInstance(SagemakerServerClient));
+
// Window
this._register(instantiationService.createInstance(BrowserWindow));

Index: sagemaker-code-editor/vscode/product.json
===================================================================
--- sagemaker-code-editor.orig/vscode/product.json
Expand All @@ -100,14 +100,14 @@ Index: sagemaker-code-editor/vscode/product.json
"applicationName": "code-oss",
"dataFolderName": ".vscode-oss",
"win32MutexName": "vscodeoss",
@@ -32,53 +32,17 @@
@@ -34,52 +34,16 @@
"urlProtocol": "code-oss",
"webviewContentExternalBaseUrlTemplate": "https://{{uuid}}.vscode-cdn.net/insider/ef65ac1ba57f57f2a3961bfe94aa20481caca4c6/out/vs/workbench/contrib/webview/browser/pre/",
"builtInExtensions": [
- {
- "name": "ms-vscode.js-debug-companion",
- "version": "1.1.3",
- "sha256": "7380a890787452f14b2db7835dfa94de538caf358ebc263f9d46dd68ac52de93",
- "version": "1.1.2",
- "sha256": "e034b8b41beb4e97e02c70f7175bd88abe66048374c2bd629f54bb33354bc2aa",
- "repo": "https://github.com/microsoft/vscode-js-debug-companion",
- "metadata": {
- "id": "99cb0b7f-7354-4278-b8da-6cc79972169d",
Expand All @@ -122,8 +122,8 @@ Index: sagemaker-code-editor/vscode/product.json
- },
- {
- "name": "ms-vscode.js-debug",
- "version": "1.93.0",
- "sha256": "9339cb8e6b77f554df54d79e71f533279cb76b0f9b04c207f633bfd507442b6a",
- "version": "1.90.0",
- "sha256": "1317dd7d1ac50641c1534a3e957ecbc94349f4fbd897acb916da11eea3208a66",
- "repo": "https://github.com/microsoft/vscode-js-debug",
- "metadata": {
- "id": "25629058-ddac-4e17-abba-74678e126c5d",
Expand Down Expand Up @@ -152,7 +152,6 @@ Index: sagemaker-code-editor/vscode/product.json
- "publisherDisplayName": "Microsoft"
- }
- }
- ]
+ ],
+ "extensionsGallery": {
+ "serviceUrl": "https://open-vsx.org/vscode/gallery",
Expand All @@ -165,13 +164,37 @@ Index: sagemaker-code-editor/vscode/product.json
+ },
+ "linkProtectionTrustedDomains": [
+ "https://open-vsx.org"
+ ]
]
Index: sagemaker-code-editor/vscode/src/vs/platform/product/common/product.ts
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/platform/product/common/product.ts
+++ sagemaker-code-editor/vscode/src/vs/platform/product/common/product.ts
@@ -59,15 +59,17 @@ else {
if (Object.keys(product).length === 0) {
Object.assign(product, {
version: '1.90.0-dev',
- nameShort: 'Code - OSS Dev',
- nameLong: 'Code - OSS Dev',
+ nameShort: 'CodeEditor',
+ nameLong: 'Code Editor',
applicationName: 'code-oss',
dataFolderName: '.vscode-oss',
+ commit: "hellocommit",
+ date: "hellodate",
urlProtocol: 'code-oss',
reportIssueUrl: 'https://github.com/microsoft/vscode/issues/new',
licenseName: 'MIT',
licenseUrl: 'https://github.com/microsoft/vscode/blob/main/LICENSE.txt',
- serverLicenseUrl: 'https://github.com/microsoft/vscode/blob/main/LICENSE.txt'
+ serverLicenseUrl: 'https://github.com/microsoft/vscode/blob/main/LICENSE.txt',
});
}
}
Index: sagemaker-code-editor/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStarted.ts
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStarted.ts
+++ sagemaker-code-editor/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStarted.ts
@@ -800,8 +800,8 @@ export class GettingStartedPage extends
@@ -779,8 +779,8 @@ export class GettingStartedPage extends EditorPane {
}));

const header = $('.header', {},
Expand Down Expand Up @@ -356,7 +379,7 @@ Index: sagemaker-code-editor/vscode/src/vs/workbench/contrib/welcomeGettingStart
===================================================================
--- sagemaker-code-editor.orig/vscode/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts
+++ sagemaker-code-editor/vscode/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts
@@ -310,8 +310,8 @@ export const walkthroughs: GettingStarte
@@ -257,8 +257,8 @@ export const walkthroughs: GettingStartedWalkthroughCo

{
id: 'SetupWeb',
Expand Down
2 changes: 1 addition & 1 deletion patches/series
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ local-storage.diff
sagemaker-integration.diff
license.diff
sagemaker-idle-extension.patch
terminal-crash-mitigation.patch
terminal-crash-mitigation.patch
2 changes: 1 addition & 1 deletion vscode
Submodule vscode updated 2593 files

0 comments on commit 328915b

Please sign in to comment.