From 0d8043f1f2e591a1b3e21cbe2350ba3653d53874 Mon Sep 17 00:00:00 2001 From: Kacper Date: Thu, 18 Dec 2025 12:25:21 +0100 Subject: [PATCH] fix(ci): rebuild node-pty after install to fix native module errors MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The --ignore-scripts flag also skips building native modules like node-pty which the server needs. Added explicit rebuild step for node-pty in test.yml and e2e-tests.yml workflows. This is more targeted than electron-builder install-app-deps which rebuilds ALL native modules and causes OOM. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- .github/workflows/e2e-tests.yml | 6 ++++++ .github/workflows/pr-check.yml | 5 +++++ .github/workflows/test.yml | 6 ++++++ 3 files changed, 17 insertions(+) diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index 14e1ad87..f90cc174 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -44,6 +44,12 @@ jobs: @rollup/rollup-linux-x64-gnu@4.53.3 \ @tailwindcss/oxide-linux-x64-gnu@4.1.17 + - name: Rebuild native modules + # Rebuild node-pty and other native modules needed for server + # This is separate from electron-builder install-app-deps to avoid OOM + run: npm rebuild node-pty + working-directory: apps/server + - name: Install Playwright browsers run: npx playwright install --with-deps chromium working-directory: apps/ui diff --git a/.github/workflows/pr-check.yml b/.github/workflows/pr-check.yml index 9c50aef2..882dbddb 100644 --- a/.github/workflows/pr-check.yml +++ b/.github/workflows/pr-check.yml @@ -46,5 +46,10 @@ jobs: @rollup/rollup-linux-x64-gnu@4.53.3 \ @tailwindcss/oxide-linux-x64-gnu@4.1.17 + - name: Rebuild native modules for Electron + # Rebuild node-pty and other native modules for Electron after npm install --ignore-scripts + # Avoids using electron-builder install-app-deps to prevent OOM issues + run: npm rebuild node-pty + - name: Run build:electron (dir only - faster CI) run: npm run build:electron:dir diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5e52e180..13194d23 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -43,6 +43,12 @@ jobs: @rollup/rollup-linux-x64-gnu@4.53.3 \ @tailwindcss/oxide-linux-x64-gnu@4.1.17 + - name: Rebuild native modules + # Rebuild node-pty and other native modules needed for server + # This is separate from electron-builder install-app-deps to avoid OOM + run: npm rebuild node-pty + working-directory: apps/server + - name: Run server tests with coverage run: npm run test:server:coverage env: