name: Backend integration tests (Windows) on: workflow_dispatch: push: branches: - "ci-windows-tests" tags: - "v*" env: CARGO_INCREMENTAL: 0 SQLX_OFFLINE: true DISABLE_EMBEDDING: true jobs: cargo_test_windows: runs-on: blacksmith-16vcpu-windows-2025 steps: - uses: actions/checkout@v4 - name: Read EE repo commit hash shell: pwsh run: | $ee_repo_ref = Get-Content .\backend\ee-repo-ref.txt echo "ee_repo_ref=$ee_repo_ref" | Out-File -FilePath $env:GITHUB_ENV -Append - name: Checkout windmill-ee-private repository uses: actions/checkout@v4 with: repository: windmill-labs/windmill-ee-private path: ./windmill-ee-private ref: ${{ env.ee_repo_ref }} token: ${{ secrets.WINDMILL_EE_PRIVATE_ACCESS }} fetch-depth: 0 - name: Substitute EE code shell: bash run: | ./backend/substitute_ee_code.sh --copy --dir ./windmill-ee-private - name: Setup PostgreSQL uses: ikalnytskyi/action-setup-postgres@v6 with: username: postgres password: changeme database: windmill port: 5432 - uses: actions-rust-lang/setup-rust-toolchain@v1 with: cache-workspaces: backend toolchain: 1.93.0 - uses: actions/setup-dotnet@v4 with: dotnet-version: "9.0.x" - uses: denoland/setup-deno@v2 with: deno-version: v2.x - uses: actions/setup-go@v2 with: go-version: 1.21.5 - uses: oven-sh/setup-bun@v2 with: bun-version: 1.3.10 - uses: actions/setup-node@v4 with: node-version: "20" - uses: astral-sh/setup-uv@v6.2.1 with: version: "0.9.25" - uses: shivammathur/setup-php@v2 with: php-version: "8.3" tools: composer - name: Install windmill CLI shell: bash run: | cd cli bash gen_wm_client.sh bun install mkdir -p "$HOME/.local/bin" printf '#!/bin/sh\nexec bun run "%s/cli/src/main.ts" "$@"\n' "$GITHUB_WORKSPACE" > "$HOME/.local/bin/wmill" chmod +x "$HOME/.local/bin/wmill" echo "$HOME/.local/bin" >> $GITHUB_PATH - name: Install OpenSSL via vcpkg run: | vcpkg.exe install openssl-windows:x64-windows vcpkg.exe install openssl:x64-windows-static vcpkg.exe integrate install - name: Free disk space (post-vcpkg) shell: pwsh run: | # vcpkg leaves multi-GB of buildtrees/downloads after installing openssl; # we only need the installed/ dir for linking. $vcpkgRoot = $env:VCPKG_INSTALLATION_ROOT foreach ($sub in @("buildtrees", "downloads", "packages")) { $path = Join-Path $vcpkgRoot $sub if (Test-Path $path) { Write-Host "Removing $path" Remove-Item -Recurse -Force -ErrorAction SilentlyContinue $path } } Get-PSDrive C | Select-Object Used,Free | Format-Table -AutoSize - name: Get runtime paths id: runtime-paths shell: pwsh run: | echo "DENO_PATH=$($(Get-Command deno).Source)" >> $env:GITHUB_OUTPUT echo "BUN_PATH=$($(Get-Command bun).Source)" >> $env:GITHUB_OUTPUT echo "NODE_BIN_PATH=$($(Get-Command node).Source)" >> $env:GITHUB_OUTPUT echo "GO_PATH=$($(Get-Command go).Source)" >> $env:GITHUB_OUTPUT echo "UV_PATH=$($(Get-Command uv).Source)" >> $env:GITHUB_OUTPUT echo "PHP_PATH=$($(Get-Command php).Source)" >> $env:GITHUB_OUTPUT echo "COMPOSER_PATH=$($(Get-Command composer).Source)" >> $env:GITHUB_OUTPUT echo "POWERSHELL_PATH=$($(Get-Command pwsh).Source)" >> $env:GITHUB_OUTPUT echo "DOTNET_PATH=$($(Get-Command dotnet).Source)" >> $env:GITHUB_OUTPUT - name: Build DuckDB FFI module working-directory: backend/windmill-duckdb-ffi-internal timeout-minutes: 30 run: | cargo build --release -p windmill_duckdb_ffi_internal New-Item -ItemType Directory -Path ..\target\debug -Force Copy-Item target\release\windmill_duckdb_ffi_internal.dll ..\target\debug\ # duckdb is bundled (~2GB of build artifacts); the DLL is the only # thing we need from this excluded-crate target dir. Remove-Item -Recurse -Force -ErrorAction SilentlyContinue target Get-PSDrive C | Select-Object Used,Free | Format-Table -AutoSize - name: Print runtime versions and env shell: pwsh run: | deno --version bun -v node --version go version python3 --version php --version pwsh --version dotnet --version echo "TEMP=$env:TEMP" echo "TMP=$env:TMP" echo "USERPROFILE=$env:USERPROFILE" echo "HOME=$env:HOME" - name: Disk space before cargo test shell: pwsh run: Get-PSDrive C | Select-Object Used,Free | Format-Table -AutoSize - name: cargo test working-directory: backend timeout-minutes: 60 env: DATABASE_URL: postgres://postgres:changeme@localhost:5432/windmill RUST_LOG: "off" RUST_LOG_STYLE: never CARGO_NET_GIT_FETCH_WITH_CLI: true # 16-vcpu runners with disabled PDB still hit LNK1180 ("insufficient # disk space") at link time with 12 parallel link jobs: each test # binary link spikes several hundred MB of transient I/O. Capping at # 8 trades ~25% wall time for headroom on the ~75GB runner disk. CARGO_BUILD_JOBS: 8 # backend/Cargo.toml sets split-debuginfo = "unpacked", which on # windows-msvc is coerced to "packed": every test-binary link spawns # the mspdbsrv.exe PDB type server and writes a large .pdb. CI needs # no debug info, so disable PDB generation for the dev/test profiles # here (avoids both LNK1318 type-server limit and PDB disk usage). CARGO_PROFILE_DEV_SPLIT_DEBUGINFO: "off" CARGO_PROFILE_TEST_SPLIT_DEBUGINFO: "off" # Tests' poll-time stack frames (deep nested async fn chains in # debug builds) reach ~1.8MB. 4MB gives ~2x headroom against flaky # overflows under parallel-test contention. RUST_MIN_STACK: 4194304 VCPKGRS_DYNAMIC: 1 OPENSSL_DIR: ${{ env.VCPKG_INSTALLATION_ROOT }}\installed\x64-windows-static DENO_PATH: ${{ steps.runtime-paths.outputs.DENO_PATH }} BUN_PATH: ${{ steps.runtime-paths.outputs.BUN_PATH }} NODE_BIN_PATH: ${{ steps.runtime-paths.outputs.NODE_BIN_PATH }} GO_PATH: ${{ steps.runtime-paths.outputs.GO_PATH }} UV_PATH: ${{ steps.runtime-paths.outputs.UV_PATH }} PHP_PATH: ${{ steps.runtime-paths.outputs.PHP_PATH }} COMPOSER_PATH: ${{ steps.runtime-paths.outputs.COMPOSER_PATH }} POWERSHELL_PATH: ${{ steps.runtime-paths.outputs.POWERSHELL_PATH }} DOTNET_PATH: ${{ steps.runtime-paths.outputs.DOTNET_PATH }} WMDEBUG_FORCE_V0_WORKSPACE_DEPENDENCIES: 1 WMDEBUG_FORCE_RUNNABLE_SETTINGS_V0: 1 WMDEBUG_FORCE_NO_LEGACY_DEBOUNCING_COMPAT: 1 run: > cargo test --no-fail-fast --features enterprise,deno_core,duckdb,license,python,rust,scoped_cache,parquet,private,csharp,php,quickjs,mcp,run_inline --all -- --nocapture --test-threads=10