Skip to content

Commit c76c40e

Browse files
jrob5756Jason Robert
andauthored
fix: add retry logic for Windows install and update lockfile (#60)
- Add retry loop (3 attempts) to install.ps1 for Windows Defender file locking issue (astral-sh/uv#4690) - Show actionable Defender exclusion hint on persistent failure - Update uv.lock with latest anthropic (0.77.0 → 0.86.0) - Bump version to 0.1.5 Co-authored-by: Jason Robert <jasonrobert@microsoft.com>
1 parent 48d06db commit c76c40e

3 files changed

Lines changed: 29 additions & 10 deletions

File tree

install.ps1

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -105,12 +105,31 @@ try {
105105
}
106106
Write-Ok "Checksum verified"
107107

108-
# --- Install ---
109-
Write-Info "Installing Conductor $tagName"
110-
uv tool install --force "git+https://github.com/$Repo.git@$tagName" -c $constraintsFile
108+
# --- Install (with retry for Windows Defender file locking) ---
109+
$maxRetries = 3
110+
$installed = $false
111+
for ($attempt = 1; $attempt -le $maxRetries; $attempt++) {
112+
if ($attempt -eq 1) {
113+
Write-Info "Installing Conductor $tagName"
114+
} else {
115+
Write-Info "Retrying install (attempt $attempt/$maxRetries)…"
116+
Start-Sleep -Seconds 2
117+
}
118+
uv tool install --force "git+https://github.com/$Repo.git@$tagName" -c $constraintsFile 2>$null
119+
if ($LASTEXITCODE -eq 0) {
120+
$installed = $true
121+
break
122+
}
123+
}
111124

112-
if ($LASTEXITCODE -ne 0) {
113-
Write-Err "uv tool install failed with exit code $LASTEXITCODE"
125+
if (-not $installed) {
126+
Write-Host ""
127+
Write-Info "Install failed after $maxRetries attempts. This is often caused by"
128+
Write-Info "Windows Defender scanning files during install. Try:"
129+
Write-Info " 1. Add a Defender exclusion: Add-MpExclusion -Path `"$env:LOCALAPPDATA\uv`""
130+
Write-Info " 2. Re-run this installer"
131+
Write-Host ""
132+
Write-Err "uv tool install failed"
114133
}
115134

116135
Write-Ok "Conductor $tagName installed"

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "conductor-cli"
3-
version = "0.1.4"
3+
version = "0.1.5"
44
description = "A CLI tool for defining and running multi-agent workflows with the GitHub Copilot SDK"
55
readme = "README.md"
66
requires-python = ">=3.12"

uv.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)