Skip to content

Commit 080047d

Browse files
Bump dependencies to latest
Key changes: - Upgrade npm dependencies to their latest - Upgrade python dependencies to their latest - Upgrade Node to 22 as 20 is end-of-life since October 2024 Other supporting changes: - Refactor `assert` with `with` (see nodejs/node#51622) - Centralize python setup via custom action for consistency - Specify bash shell for correct argument handling on Windows using latest npm (npm/cli#6041)
1 parent 5155f93 commit 080047d

File tree

16 files changed

+5079
-3594
lines changed

16 files changed

+5079
-3594
lines changed

.github/actions/npm-install-dependencies/action.yml

+6-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@ runs:
66
using: composite
77
steps:
88
-
9-
name: Run `npm ci` with retries
9+
name: Update Browserslist DB
1010
shell: bash
11+
run: npx update-browserslist-db@latest
12+
working-directory: ${{ inputs.working-directory }}
13+
-
14+
name: Run `npm ci` with retries
15+
shell: bash # Required for correct argument passing (--)
1116
run: npm run install-deps -- --ci
1217
working-directory: ${{ inputs.working-directory }}

.github/actions/setup-node/action.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ runs:
55
name: Setup node
66
uses: actions/setup-node@v4
77
with:
8-
node-version: 20.x
8+
node-version: 22.x
99
# check-latest: true # Newest versions can potentially have undiscovered bugs or regressions
+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
runs:
2+
using: composite
3+
steps:
4+
-
5+
name: Set up Python
6+
uses: actions/setup-python@v5
7+
with:
8+
python-version: '3.13'

.github/workflows/checks.build.yaml

+6
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,11 @@ jobs:
3030
uses: ./.github/actions/npm-install-dependencies
3131
-
3232
name: Build web
33+
shell: bash # Required for correct argument passing (--)
3334
run: npm run build -- --mode ${{ matrix.mode }}
3435
-
3536
name: Verify web build artifacts
37+
shell: bash # Required for correct argument passing (--)
3638
run: npm run check:verify-build-artifacts -- --web
3739

3840
build-desktop:
@@ -58,15 +60,19 @@ jobs:
5860
uses: ./.github/actions/npm-install-dependencies
5961
-
6062
name: Prebuild desktop
63+
shell: bash # Required for correct argument passing (--)
6164
run: npm run electron:prebuild -- --mode ${{ matrix.mode }}
6265
-
6366
name: Verify unbundled desktop build artifacts
67+
shell: bash # Required for correct argument passing (--)
6468
run: npm run check:verify-build-artifacts -- --electron-unbundled
6569
-
6670
name: Build (bundle and package) desktop application
71+
shell: bash # Required for correct argument passing (--)
6772
run: npm run electron:build -- --publish never
6873
-
6974
name: Verify bundled desktop build artifacts
75+
shell: bash # Required for correct argument passing (--)
7076
run: npm run check:verify-build-artifacts -- --electron-bundled
7177

7278
build-docker:

.github/workflows/checks.quality.yaml

+4-8
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,8 @@ jobs:
6363
name: Setup node
6464
uses: ./.github/actions/setup-node
6565
-
66-
name: Set up Python
67-
uses: actions/setup-python@v5
68-
with:
69-
python-version: '3.x'
66+
name: Setup node
67+
uses: ./.github/actions/setup-python
7068
-
7169
name: Install dependencies
7270
run: |
@@ -90,10 +88,8 @@ jobs:
9088
name: Setup node
9189
uses: ./.github/actions/setup-node
9290
-
93-
name: Set up Python
94-
uses: actions/setup-python@v5
95-
with:
96-
python-version: '3.x'
91+
name: Setup node
92+
uses: ./.github/actions/setup-python
9793
-
9894
name: Install dependencies
9995
run: python3 -m pip install -r ./scripts/validate-collections-yaml/requirements.txt

.github/workflows/checks.scripts.yaml

+3-4
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ jobs:
5555
uses: ./.github/actions/npm-install-dependencies
5656
-
5757
name: Run install-deps
58+
shell: bash # Required for correct argument passing (--)
5859
run: ${{ matrix.install-command }}
5960

6061
configure-vscode:
@@ -74,10 +75,8 @@ jobs:
7475
name: Checkout
7576
uses: actions/checkout@v4
7677
-
77-
name: Set up Python
78-
uses: actions/setup-python@v5
79-
with:
80-
python-version: '3.x'
78+
name: Setup node
79+
uses: ./.github/actions/setup-python
8180
-
8281
name: Install VSCode
8382
run: ${{ matrix.os.install-vscode-command }}

.github/workflows/release.desktop.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ jobs:
3737
-
3838
name: Build and publish
3939
run: npm run electron:build -- --publish always
40+
shell: bash # Required for correct argument passing (--)
4041
env:
4142
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4243
EP_GH_IGNORE_TIME: true # Otherwise publishing fails if GitHub release is more than 2 hours old https://github.com/electron-userland/electron-builder/issues/2074

.github/workflows/release.site.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ jobs:
9898
-
9999
name: "App: Verify web build artifacts"
100100
run: npm run check:verify-build-artifacts -- --web
101+
shell: bash # Required for correct argument passing (--)
101102
working-directory: app
102103
-
103104
name: "App: Deploy to S3"

cypress.config.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { defineConfig } from 'cypress';
22
import ViteConfig from './vite.config';
3-
import cypressDirs from './cypress-dirs.json' assert { type: 'json' };
3+
import cypressDirs from './cypress-dirs.json' with { type: 'json' };
44

55
export default defineConfig({
66
fixturesFolder: `${cypressDirs.base}/fixtures`,

electron.vite.config.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { mergeConfig, type UserConfig } from 'vite';
33
import { defineConfig, externalizeDepsPlugin } from 'electron-vite';
44
import { getAliases, getClientEnvironmentVariables } from './vite-config-helper';
55
import { createVueConfig } from './vite.config';
6-
import distDirs from './dist-dirs.json' assert { type: 'json' };
6+
import distDirs from './dist-dirs.json' with { type: 'json' };
77

88
const MAIN_ENTRY_FILE = resolvePathFromProjectRoot('src/presentation/electron/main/index.ts');
99
const PRELOAD_ENTRY_FILE = resolvePathFromProjectRoot('src/presentation/electron/preload/index.ts');

0 commit comments

Comments
 (0)