From 622098db3ff378fadbfd4871f6f919de810b99c1 Mon Sep 17 00:00:00 2001 From: Jiri Zbytovsky Date: Wed, 2 Oct 2024 13:59:38 +0200 Subject: [PATCH] chore(suite): bump electron to 32 --- package.json | 2 +- .../electron-main-process/package.json | 2 +- .../package.json | 2 +- .../electron-renderer-with-popup/package.json | 2 +- .../configs/desktop.webpack.config.ts | 2 +- packages/suite-desktop-api/package.json | 2 +- packages/suite-desktop-core/package.json | 2 +- packages/suite-desktop/package.json | 2 +- shell.nix | 7 ++++++- yarn.lock | 20 +++++++++---------- 10 files changed, 24 insertions(+), 19 deletions(-) diff --git a/package.json b/package.json index 689afab6f41..0206503c0f3 100644 --- a/package.json +++ b/package.json @@ -103,7 +103,7 @@ "type-fest": "4.24.0", "bcrypto": "5.4.0", "react": "18.2.0", - "electron": "31.6.0", + "electron": "32.1.2", "@types/node": "20.12.7", "@types/react": "18.2.55", "bn.js": "5.2.1" diff --git a/packages/connect-examples/electron-main-process/package.json b/packages/connect-examples/electron-main-process/package.json index eb3dc19a5ca..7777ce817d5 100644 --- a/packages/connect-examples/electron-main-process/package.json +++ b/packages/connect-examples/electron-main-process/package.json @@ -55,7 +55,7 @@ "@trezor/connect": "workspace:*" }, "devDependencies": { - "electron": "31.6.0", + "electron": "32.1.2", "electron-builder": "25.0.5" } } diff --git a/packages/connect-examples/electron-renderer-with-assets/package.json b/packages/connect-examples/electron-renderer-with-assets/package.json index 626f60fcd52..c724f26b64f 100644 --- a/packages/connect-examples/electron-renderer-with-assets/package.json +++ b/packages/connect-examples/electron-renderer-with-assets/package.json @@ -60,7 +60,7 @@ "babel-loader": "^9.1.3", "concurrently": "^8.2.2", "copy-webpack-plugin": "^12.0.2", - "electron": "31.6.0", + "electron": "32.1.2", "electron-builder": "25.0.5", "html-webpack-plugin": "^5.6.0", "terser-webpack-plugin": "^5.3.9", diff --git a/packages/connect-examples/electron-renderer-with-popup/package.json b/packages/connect-examples/electron-renderer-with-popup/package.json index 4c028cb4990..d5f5bed36df 100644 --- a/packages/connect-examples/electron-renderer-with-popup/package.json +++ b/packages/connect-examples/electron-renderer-with-popup/package.json @@ -52,7 +52,7 @@ } }, "devDependencies": { - "electron": "31.6.0", + "electron": "32.1.2", "electron-builder": "25.0.5" } } diff --git a/packages/suite-build/configs/desktop.webpack.config.ts b/packages/suite-build/configs/desktop.webpack.config.ts index 5e1b7d52c64..b249c022a97 100644 --- a/packages/suite-build/configs/desktop.webpack.config.ts +++ b/packages/suite-build/configs/desktop.webpack.config.ts @@ -17,7 +17,7 @@ const baseDirUI = getPathForProject('desktop-ui'); const baseDir = getPathForProject('desktop'); const config: webpack.Configuration = { - target: 'browserslist:Chrome >= 126', // Electron 31 is running on chromium 126 + target: 'browserslist:Chrome >= 128', // Electron 32 is running on chromium 128 entry: [path.join(baseDirUI, 'src', 'index.tsx')], output: { path: path.join(baseDir, 'build'), diff --git a/packages/suite-desktop-api/package.json b/packages/suite-desktop-api/package.json index a76c870b93e..b065ca76887 100644 --- a/packages/suite-desktop-api/package.json +++ b/packages/suite-desktop-api/package.json @@ -19,6 +19,6 @@ "type-check": "yarn g:tsc --build tsconfig.json" }, "dependencies": { - "electron": "31.6.0" + "electron": "32.1.2" } } diff --git a/packages/suite-desktop-core/package.json b/packages/suite-desktop-core/package.json index 4cee8d222cf..30da69f55cb 100644 --- a/packages/suite-desktop-core/package.json +++ b/packages/suite-desktop-core/package.json @@ -50,7 +50,7 @@ "@trezor/trezor-user-env-link": "workspace:*", "@trezor/type-utils": "workspace:*", "@types/electron-localshortcut": "^3.1.3", - "electron": "31.6.0", + "electron": "32.1.2", "fs-extra": "^11.2.0", "glob": "^10.3.10", "terser-webpack-plugin": "^5.3.9", diff --git a/packages/suite-desktop/package.json b/packages/suite-desktop/package.json index ba6805b1777..6b482e8955e 100644 --- a/packages/suite-desktop/package.json +++ b/packages/suite-desktop/package.json @@ -31,7 +31,7 @@ }, "devDependencies": { "@electron/notarize": "2.5.0", - "electron": "31.6.0", + "electron": "32.1.2", "electron-builder": "25.0.5", "glob": "^10.3.10" } diff --git a/shell.nix b/shell.nix index e4e06149d76..fb20ed23bdb 100644 --- a/shell.nix +++ b/shell.nix @@ -1,3 +1,6 @@ +# ATTENTION +# NixOS is not fully supported, some configuration may be necessary, see comments below + # pinned to nixos-24.05 on commit https://github.com/NixOS/nixpkgs/commit/759537f06e6999e141588ff1c9be7f3a5c060106 with import (builtins.fetchTarball { @@ -8,7 +11,9 @@ with import let # unstable packages - electron = electron_31; # use the same version as defined in packages/suite-desktop/package.json + # ATTENTION: this does not match the actual required version defined in packages/suite-desktop/package.json + # (the required version is not yet in NixOS repository) + electron = electron_31; nodejs = nodejs_20; # use older gcc. 10.2.0 with glibc 2.32 for node_modules bindings. # electron-builder is packing the app with glibc 2.32, bindings should not be compiled with newer version. diff --git a/yarn.lock b/yarn.lock index 0647970a7ce..7e70ec6e9e1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -11848,7 +11848,7 @@ __metadata: version: 0.0.0-use.local resolution: "@trezor/suite-desktop-api@workspace:packages/suite-desktop-api" dependencies: - electron: "npm:31.6.0" + electron: "npm:32.1.2" languageName: unknown linkType: soft @@ -11885,7 +11885,7 @@ __metadata: "@trezor/utils": "workspace:*" "@types/electron-localshortcut": "npm:^3.1.3" chalk: "npm:^4.1.2" - electron: "npm:31.6.0" + electron: "npm:32.1.2" electron-localshortcut: "npm:^3.2.1" electron-store: "npm:8.2.0" electron-updater: "npm:6.3.4" @@ -11935,7 +11935,7 @@ __metadata: dependencies: "@electron/notarize": "npm:2.5.0" blake-hash: "npm:^2.0.0" - electron: "npm:31.6.0" + electron: "npm:32.1.2" electron-builder: "npm:25.0.5" electron-localshortcut: "npm:^3.2.1" electron-store: "npm:8.2.0" @@ -18044,7 +18044,7 @@ __metadata: resolution: "connect-example-electron-main@workspace:packages/connect-examples/electron-main-process" dependencies: "@trezor/connect": "workspace:*" - electron: "npm:31.6.0" + electron: "npm:32.1.2" electron-builder: "npm:25.0.5" languageName: unknown linkType: soft @@ -18053,7 +18053,7 @@ __metadata: version: 0.0.0-use.local resolution: "connect-example-electron-renderer-popup@workspace:packages/connect-examples/electron-renderer-with-popup" dependencies: - electron: "npm:31.6.0" + electron: "npm:32.1.2" electron-builder: "npm:25.0.5" languageName: unknown linkType: soft @@ -18066,7 +18066,7 @@ __metadata: babel-loader: "npm:^9.1.3" concurrently: "npm:^8.2.2" copy-webpack-plugin: "npm:^12.0.2" - electron: "npm:31.6.0" + electron: "npm:32.1.2" electron-builder: "npm:25.0.5" html-webpack-plugin: "npm:^5.6.0" terser-webpack-plugin: "npm:^5.3.9" @@ -20542,16 +20542,16 @@ __metadata: languageName: node linkType: hard -"electron@npm:31.6.0": - version: 31.6.0 - resolution: "electron@npm:31.6.0" +"electron@npm:32.1.2": + version: 32.1.2 + resolution: "electron@npm:32.1.2" dependencies: "@electron/get": "npm:^2.0.0" "@types/node": "npm:^20.9.0" extract-zip: "npm:^2.0.1" bin: electron: cli.js - checksum: 10/ef304dd279a6f01143de000d3be420bde8f6feb5b72387c2b22e64fd97e1d5b80a0e82e4f2dee660b36a8a682e4f9cbcd2e6d2f73f5e7ba4e84d8bfb03c1d8e2 + checksum: 10/a4793dd12b2d1dffff53420092ac7612eee41d193f07e847783136ee296b5380abb169eb1a4c1929b01a99b1d93bf53f071f2c5128e8241e70ec930d303fba51 languageName: node linkType: hard