From bc1775823139f635d374272712cce4f0c4ecdb53 Mon Sep 17 00:00:00 2001 From: Wendong-Fan <133094783+Wendong-Fan@users.noreply.github.com> Date: Wed, 21 Jan 2026 23:43:52 +0800 Subject: [PATCH 1/5] Fix win prebuilt 886f967 (#1004) Co-authored-by: 4pmtong --- electron/main/init.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/electron/main/init.ts b/electron/main/init.ts index 2b0ace8c..469777a7 100644 --- a/electron/main/init.ts +++ b/electron/main/init.ts @@ -225,14 +225,13 @@ export async function startBackend(setPort?: (port: number) => void): Promise Date: Wed, 21 Jan 2026 23:59:26 +0800 Subject: [PATCH 2/5] chore: update yml file (#1002) --- .github/workflows/build-view.yml | 22 ++++++++++++++-------- .github/workflows/build.yml | 18 ++++++++++++------ 2 files changed, 26 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build-view.yml b/.github/workflows/build-view.yml index 8cc231ec..0e7d4186 100644 --- a/.github/workflows/build-view.yml +++ b/.github/workflows/build-view.yml @@ -14,31 +14,38 @@ jobs: strategy: matrix: include: - - os: warp-macos-15-arm64-12x + - os: [self-hosted, macOS, ARM64] arch: arm64 + artifact_name: macos-arm64 - os: windows-latest arch: x64 + artifact_name: windows-latest - os: ubuntu-latest arch: x64 + artifact_name: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v4 + with: + clean: true - name: Setup Node.js + if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-node@v6 with: node-version: 20 - name: Setup Python + if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-python@v6 with: python-version: '3.11' - name: Install Python Dependencies run: | - python -m pip install --upgrade pip - pip install uv + python3 -m pip install --upgrade pip + pip3 install uv - name: Install bun run: npm install -g bun @@ -78,7 +85,6 @@ jobs: run: npm run build -- --arch ${{ matrix.arch }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Signing variables (CSC_LINK, CSC_KEY_PASSWORD) are omitted for Windows VITE_BASE_URL: ${{ secrets.VITE_BASE_URL }} VITE_STACK_PROJECT_ID: ${{ secrets.VITE_STACK_PROJECT_ID }} VITE_STACK_PUBLISHABLE_CLIENT_KEY: ${{ secrets.VITE_STACK_PUBLISHABLE_CLIENT_KEY }} @@ -102,7 +108,7 @@ jobs: if: runner.os == 'macOS' uses: actions/upload-artifact@v6 with: - name: release-${{ matrix.os }}-${{ matrix.arch }} + name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | release/*.dmg retention-days: 5 @@ -111,7 +117,7 @@ jobs: if: runner.os == 'Windows' uses: actions/upload-artifact@v6 with: - name: release-${{ matrix.os }}-${{ matrix.arch }} + name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | release/*.exe retention-days: 5 @@ -120,7 +126,7 @@ jobs: if: runner.os == 'Linux' uses: actions/upload-artifact@v6 with: - name: release-${{ matrix.os }}-${{ matrix.arch }} + name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | release/*.AppImage retention-days: 5 @@ -135,7 +141,7 @@ jobs: - name: Download mac-arm64 artifact uses: actions/download-artifact@v7 with: - name: release-warp-macos-15-arm64-6x-arm64 + name: release-macos-arm64-arm64 path: temp-mac-arm64 - name: Download win-x64 artifact diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b66b8981..44c65de1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,31 +25,38 @@ jobs: strategy: matrix: include: - - os: warp-macos-15-arm64-12x + - os: [self-hosted, macOS, ARM64] arch: arm64 + artifact_name: macos-arm64 - os: windows-latest arch: x64 + artifact_name: windows-latest - os: ubuntu-latest arch: x64 + artifact_name: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v4 + with: + clean: true - name: Setup Node.js + if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-node@v6 with: node-version: 20 - name: Setup Python + if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-python@v6 with: python-version: "3.11" - name: Install Python Dependencies run: | - python -m pip install --upgrade pip - pip install uv + python3 -m pip install --upgrade pip + pip3 install uv - name: Install Dependencies run: npm install @@ -83,7 +90,6 @@ jobs: run: npm run build -- --arch ${{ matrix.arch }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Signing variables (CSC_LINK, CSC_KEY_PASSWORD) are omitted for Windows VITE_BASE_URL: ${{ secrets.VITE_BASE_URL }} VITE_STACK_PROJECT_ID: ${{ secrets.VITE_STACK_PROJECT_ID }} VITE_STACK_PUBLISHABLE_CLIENT_KEY: ${{ secrets.VITE_STACK_PUBLISHABLE_CLIENT_KEY }} @@ -103,7 +109,7 @@ jobs: - name: Upload Artifact uses: actions/upload-artifact@v6 with: - name: release-${{ matrix.os }}-${{ matrix.arch }} + name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | release/* !release/builder-debug.yml @@ -120,7 +126,7 @@ jobs: - name: Download mac-arm64 artifact uses: actions/download-artifact@v7 with: - name: release-warp-macos-15-arm64-6x-arm64 + name: release-macos-arm64-arm64 path: temp-mac-arm64 - name: Download win-x64 artifact From e8a7e779fac9070106e9c58aa8bf8b4a28813320 Mon Sep 17 00:00:00 2001 From: Wendong-Fan Date: Thu, 22 Jan 2026 00:15:47 +0800 Subject: [PATCH 3/5] chore: add electron verification steps for self-hosted runner --- .github/workflows/build-view.yml | 44 ++++++++++++++++++++++++++++++++ .github/workflows/build.yml | 44 ++++++++++++++++++++++++++++++++ 2 files changed, 88 insertions(+) diff --git a/.github/workflows/build-view.yml b/.github/workflows/build-view.yml index 0e7d4186..0a3469ad 100644 --- a/.github/workflows/build-view.yml +++ b/.github/workflows/build-view.yml @@ -30,6 +30,13 @@ jobs: with: clean: true + # Clean node_modules on self-hosted runner to ensure fresh install + - name: Clean node_modules (self-hosted) + if: contains(matrix.os, 'self-hosted') + run: | + rm -rf node_modules + rm -rf release + - name: Setup Node.js if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-node@v6 @@ -53,6 +60,20 @@ jobs: - name: Install Dependencies run: npm install + # Verify Electron installation on macOS + - name: Verify Electron Installation (macOS) + if: runner.os == 'macOS' + run: | + echo "Checking Electron installation..." + ls -la node_modules/electron/dist/ || echo "Electron dist not found" + if [ -d "node_modules/electron/dist/Electron.app" ]; then + echo "✅ Electron.app found" + ls -la "node_modules/electron/dist/Electron.app/Contents/Frameworks/" | head -5 + else + echo "❌ Electron.app NOT found - this will cause build failure" + exit 1 + fi + # Install libfuse2 for Linux AppImage builds - name: Install libfuse2 (Linux) if: runner.os == 'Linux' @@ -104,6 +125,29 @@ jobs: VITE_STACK_SECRET_SERVER_KEY: ${{ secrets.VITE_STACK_SECRET_SERVER_KEY }} USE_NPM_INSTALL_BUN: 'true' + # Verify built app contains Electron Framework + - name: Verify Built App (macOS) + if: runner.os == 'macOS' + run: | + echo "Checking built app..." + APP_PATH=$(find release -name "*.app" -type d | head -1) + if [ -n "$APP_PATH" ]; then + echo "Found app at: $APP_PATH" + FRAMEWORKS_PATH="$APP_PATH/Contents/Frameworks" + if [ -d "$FRAMEWORKS_PATH/Electron Framework.framework" ]; then + echo "✅ Electron Framework found" + ls -la "$FRAMEWORKS_PATH/" | head -10 + else + echo "❌ Electron Framework NOT found in built app!" + echo "Contents of Frameworks directory:" + ls -la "$FRAMEWORKS_PATH/" 2>/dev/null || echo "Frameworks directory does not exist" + exit 1 + fi + else + echo "No .app found in release directory" + ls -la release/ + fi + - name: Upload Artifact (macOS - dmg only) if: runner.os == 'macOS' uses: actions/upload-artifact@v6 diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 44c65de1..136ffa2c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -41,6 +41,13 @@ jobs: with: clean: true + # Clean node_modules on self-hosted runner to ensure fresh install + - name: Clean node_modules (self-hosted) + if: contains(matrix.os, 'self-hosted') + run: | + rm -rf node_modules + rm -rf release + - name: Setup Node.js if: "!contains(matrix.os, 'self-hosted')" uses: actions/setup-node@v6 @@ -61,6 +68,20 @@ jobs: - name: Install Dependencies run: npm install + # Verify Electron installation on macOS + - name: Verify Electron Installation (macOS) + if: runner.os == 'macOS' + run: | + echo "Checking Electron installation..." + ls -la node_modules/electron/dist/ || echo "Electron dist not found" + if [ -d "node_modules/electron/dist/Electron.app" ]; then + echo "✅ Electron.app found" + ls -la "node_modules/electron/dist/Electron.app/Contents/Frameworks/" | head -5 + else + echo "❌ Electron.app NOT found - this will cause build failure" + exit 1 + fi + # Install libfuse2 for Linux AppImage builds - name: Install libfuse2 (Linux) if: runner.os == 'Linux' @@ -106,6 +127,29 @@ jobs: VITE_STACK_PUBLISHABLE_CLIENT_KEY: ${{ secrets.VITE_STACK_PUBLISHABLE_CLIENT_KEY }} VITE_STACK_SECRET_SERVER_KEY: ${{ secrets.VITE_STACK_SECRET_SERVER_KEY }} + # Verify built app contains Electron Framework + - name: Verify Built App (macOS) + if: runner.os == 'macOS' + run: | + echo "Checking built app..." + APP_PATH=$(find release -name "*.app" -type d | head -1) + if [ -n "$APP_PATH" ]; then + echo "Found app at: $APP_PATH" + FRAMEWORKS_PATH="$APP_PATH/Contents/Frameworks" + if [ -d "$FRAMEWORKS_PATH/Electron Framework.framework" ]; then + echo "✅ Electron Framework found" + ls -la "$FRAMEWORKS_PATH/" | head -10 + else + echo "❌ Electron Framework NOT found in built app!" + echo "Contents of Frameworks directory:" + ls -la "$FRAMEWORKS_PATH/" 2>/dev/null || echo "Frameworks directory does not exist" + exit 1 + fi + else + echo "No .app found in release directory" + ls -la release/ + fi + - name: Upload Artifact uses: actions/upload-artifact@v6 with: From 1919919c7ca3c781754c2f500eaa4ce55aa0960c Mon Sep 17 00:00:00 2001 From: Wendong-Fan Date: Thu, 22 Jan 2026 03:18:58 +0800 Subject: [PATCH 4/5] fix: use zip instead of dmg to avoid Electron Framework missing issue --- .github/workflows/build-view.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-view.yml b/.github/workflows/build-view.yml index 0a3469ad..bfc780f2 100644 --- a/.github/workflows/build-view.yml +++ b/.github/workflows/build-view.yml @@ -148,13 +148,13 @@ jobs: ls -la release/ fi - - name: Upload Artifact (macOS - dmg only) + - name: Upload Artifact (macOS - zip instead of dmg) if: runner.os == 'macOS' uses: actions/upload-artifact@v6 with: name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | - release/*.dmg + release/*-mac.zip retention-days: 5 - name: Upload Artifact (Windows - exe only) @@ -200,15 +200,15 @@ jobs: name: release-ubuntu-latest-x64 path: temp-linux-x64 - # Move only dmg files for macOS, exe files for Windows, and AppImage for Linux + # Move zip files for macOS, exe files for Windows, and AppImage for Linux - name: Move files to clean folders shell: bash run: | - # mac-arm64 - only move dmg files + # mac-arm64 - move zip files (not dmg due to Electron Framework issue) if [ -d "temp-mac-arm64/release" ]; then - find temp-mac-arm64/release -name "*.dmg" -exec mv {} release/mac-arm64/ \; || true + find temp-mac-arm64/release -name "*-mac.zip" -exec mv {} release/mac-arm64/ \; || true else - find temp-mac-arm64 -name "*.dmg" -exec mv {} release/mac-arm64/ \; || true + find temp-mac-arm64 -name "*-mac.zip" -exec mv {} release/mac-arm64/ \; || true fi # win-x64 - only move exe files From 35f4ca259d55d09751ad8fa27a1a6b3c333bc18a Mon Sep 17 00:00:00 2001 From: Wendong-Fan Date: Thu, 22 Jan 2026 06:57:01 +0800 Subject: [PATCH 5/5] Revert "fix: use zip instead of dmg to avoid Electron Framework missing issue" This reverts commit 1919919c7ca3c781754c2f500eaa4ce55aa0960c. --- .github/workflows/build-view.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-view.yml b/.github/workflows/build-view.yml index bfc780f2..0a3469ad 100644 --- a/.github/workflows/build-view.yml +++ b/.github/workflows/build-view.yml @@ -148,13 +148,13 @@ jobs: ls -la release/ fi - - name: Upload Artifact (macOS - zip instead of dmg) + - name: Upload Artifact (macOS - dmg only) if: runner.os == 'macOS' uses: actions/upload-artifact@v6 with: name: release-${{ matrix.artifact_name }}-${{ matrix.arch }} path: | - release/*-mac.zip + release/*.dmg retention-days: 5 - name: Upload Artifact (Windows - exe only) @@ -200,15 +200,15 @@ jobs: name: release-ubuntu-latest-x64 path: temp-linux-x64 - # Move zip files for macOS, exe files for Windows, and AppImage for Linux + # Move only dmg files for macOS, exe files for Windows, and AppImage for Linux - name: Move files to clean folders shell: bash run: | - # mac-arm64 - move zip files (not dmg due to Electron Framework issue) + # mac-arm64 - only move dmg files if [ -d "temp-mac-arm64/release" ]; then - find temp-mac-arm64/release -name "*-mac.zip" -exec mv {} release/mac-arm64/ \; || true + find temp-mac-arm64/release -name "*.dmg" -exec mv {} release/mac-arm64/ \; || true else - find temp-mac-arm64 -name "*-mac.zip" -exec mv {} release/mac-arm64/ \; || true + find temp-mac-arm64 -name "*.dmg" -exec mv {} release/mac-arm64/ \; || true fi # win-x64 - only move exe files