From 34c6751bf8ae4e343f908d8aee691a4778f1d3a2 Mon Sep 17 00:00:00 2001 From: Asher Date: Thu, 15 Aug 2024 21:33:21 -0800 Subject: [PATCH] Update VS Code to 1.92.2 (#6941) * Update VS Code to 1.92.2 * Use server-main.js to load VS Code It looks like the bootstrap files are now bundled so we can no longer require them. We could make them included again, but maybe it is better to go through the main entrypoint anyway because it includes some nls stuff which is maybe necessary. This also fixes what looks like a bug where we could create two servers if two requests came in. I am not sure what the practical consequences of that would be, but it will no longer do that. * Drop es2020 patch Unfortunately, VS Code will not load with this. It seems to be because `this` is being used in static properties, and it becomes `void 0` for some reason under the es2020 target. For example: static PREFIX_BY_CATEGORY = `${this.PREFIX}${this.SCOPE_PREFIX}`; becomes AbstractGotoSymbolQuickAccessProvider.PREFIX_BY_CATEGORY = `${(void 0).PREFIX}${(void 0).SCOPE_PREFIX}`; Which, obviously, will not work. Older versions of Safari (and maybe other browsers) are likely affected. * Fix display language * Update Playwright I think maybe because of the dropped es2020 patch that Webkit is now failing because it is too old. * Do not wait for networkidle in e2e tests I am not sure what is going on but some tests on Webkit are timing out and it seems the page is loaded but something is still trying to download. Not good, but for now try to at least get the tests passing. --- CHANGELOG.md | 13 + lib/vscode | 2 +- patches/base-path.diff | 44 ++- patches/clipboard.diff | 4 +- patches/disable-builtin-ext-update.diff | 2 +- patches/display-language.diff | 285 +++++++------- patches/external-file-actions.diff | 6 +- patches/getting-started.diff | 10 +- patches/integration.diff | 17 +- patches/keepalive.diff | 2 +- patches/local-storage.diff | 2 +- patches/logout.diff | 2 +- patches/marketplace.diff | 14 +- patches/proxy-uri.diff | 2 +- patches/safari.diff | 68 ---- patches/series | 3 +- patches/service-worker.diff | 2 +- patches/sourcemaps.diff | 6 +- patches/store-socket.diff | 6 +- patches/telemetry.diff | 18 +- patches/update-check.diff | 2 +- patches/webview.diff | 28 +- src/node/cli.ts | 5 - src/node/main.ts | 16 +- src/node/routes/vscode.ts | 69 +++- src/node/util.ts | 26 -- test/e2e/models/CodeServer.ts | 2 +- test/package.json | 4 +- test/yarn.lock | 496 ++---------------------- 29 files changed, 352 insertions(+), 804 deletions(-) delete mode 100644 patches/safari.diff diff --git a/CHANGELOG.md b/CHANGELOG.md index ef97088f8..5b0af9972 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,19 @@ Code v99.99.999 ## Unreleased +Code v1.92.1 + +### Breaking changes + +- Dropped a patch that changed the compile target from es2022 to es2020 because + it no longer works with the way VS Code uses static properties. This may break + older browsers, so those browsers will either have to be updated or use an + older version of code-server. + +### Changed + +- Updated to Code 1.92.1. + ## [4.91.0](https://github.com/coder/code-server/releases/tag/v4.91.0) - 2024-07-10 Code v1.91.0 diff --git a/lib/vscode b/lib/vscode index f1e16e1e6..fee1edb8d 160000 --- a/lib/vscode +++ b/lib/vscode @@ -1 +1 @@ -Subproject commit f1e16e1e6214d7c44d078b1f0607b2388f29d729 +Subproject commit fee1edb8d6d72a0ddff41e5f71a671c23ed924b9 diff --git a/patches/base-path.diff b/patches/base-path.diff index 6705ec088..05bfbbf4a 100644 --- a/patches/base-path.diff +++ b/patches/base-path.diff @@ -86,10 +86,10 @@ Index: code-server/lib/vscode/src/vs/code/browser/workbench/workbench.html -@@ -38,7 +38,7 @@ - - +@@ -40,7 +40,7 @@