diff --git a/scripts/e2e/parallels/windows-git.ts b/scripts/e2e/parallels/windows-git.ts index d77f9168c7fc..e2485d7fe98e 100644 --- a/scripts/e2e/parallels/windows-git.ts +++ b/scripts/e2e/parallels/windows-git.ts @@ -125,7 +125,7 @@ if (Test-Path $portableGit) { Remove-Item $portableGit -Recurse -Force } New-Item -ItemType Directory -Force -Path $portableGit | Out-Null -curl.exe -fsSL ${psSingleQuote(minGitUrl)} -o $archive +curl.exe -fsSL --connect-timeout 10 --max-time 120 --retry 2 --retry-delay 2 ${psSingleQuote(minGitUrl)} -o $archive tar.exe -xf $archive -C $portableGit Remove-Item $archive -Force -ErrorAction SilentlyContinue $env:PATH = "$portableGit\\cmd;$portableGit\\mingw64\\bin;$portableGit\\usr\\bin;$env:PATH" diff --git a/scripts/e2e/parallels/windows-smoke.ts b/scripts/e2e/parallels/windows-smoke.ts index 800c3d237338..33c51ec7703b 100755 --- a/scripts/e2e/parallels/windows-smoke.ts +++ b/scripts/e2e/parallels/windows-smoke.ts @@ -542,7 +542,7 @@ ${cleanScript}`, const versionArg = this.installVersion ? ` -Tag ${psSingleQuote(this.installVersion)}` : ""; this.guestPowerShell( `$ErrorActionPreference = 'Stop' -$script = Invoke-RestMethod -Uri ${psSingleQuote(this.options.installUrl)} +$script = Invoke-RestMethod -Uri ${psSingleQuote(this.options.installUrl)} -TimeoutSec 120 & ([scriptblock]::Create($script))${versionArg} -NoOnboard if ($LASTEXITCODE -ne 0) { throw "installer failed with exit code $LASTEXITCODE" } Invoke-OpenClaw --version @@ -559,7 +559,7 @@ if ($LASTEXITCODE -ne 0) { throw "openclaw --version failed with exit code $LAST this.guestPowerShell( `$ErrorActionPreference = 'Stop' $tgz = Join-Path $env:TEMP ${psSingleQuote(tempName)} -curl.exe -fsSL ${psSingleQuote(tgzUrl)} -o $tgz +curl.exe -fsSL --connect-timeout 10 --max-time 120 --retry 2 --retry-delay 2 ${psSingleQuote(tgzUrl)} -o $tgz npm.cmd install -g $tgz --no-fund --no-audit --loglevel=error if ($LASTEXITCODE -ne 0) { throw "npm install failed with exit code $LASTEXITCODE" } Invoke-OpenClaw --version diff --git a/test/scripts/parallels-smoke-model.test.ts b/test/scripts/parallels-smoke-model.test.ts index e81e7de77734..bf0d0a33aa48 100644 --- a/test/scripts/parallels-smoke-model.test.ts +++ b/test/scripts/parallels-smoke-model.test.ts @@ -1275,6 +1275,10 @@ if (isPrlctl) { expect(windowsGit.indexOf('"MinGit-2.53.0.2-64-bit.zip"')).toBeLessThan( windowsGit.indexOf('"MinGit-2.53.0.2-arm64.zip"'), ); + expect(combined.match(/curl\.exe -fsSL --connect-timeout 10 --max-time 120 --retry 2/g)) + .toHaveLength(2); + expect(script).toContain("Invoke-RestMethod -Uri"); + expect(script).toContain("-TimeoutSec 120"); expect(windowsGit).toContain('if "-64-bit." in name:'); expect(windowsGit).toContain('elif "-arm64." in name:'); });