Skip to content

Commit 22cd57a

Browse files
bewithgauravCopilot
andcommitted
FIX: stabilize release builds on macOS and ARM64 Linux
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent acdb42c commit 22cd57a

2 files changed

Lines changed: 14 additions & 19 deletions

File tree

‎OneBranchPipelines/stages/build-linux-single-stage.yml‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ stages:
4848
name: Python-1ES-pool
4949
demands:
5050
- imageOverride -equals PYTHON-1ES-UB2404
51-
# Extended timeout for multi-version builds + testing (5 Python versions × build + test time)
52-
timeoutInMinutes: 120
51+
# Six serial build/test cycles exceed two hours under QEMU-based ARM64 emulation.
52+
timeoutInMinutes: 180
5353

5454
variables:
5555
# Disable BinSkim for Linux - requires ICU libraries not available in manylinux/musllinux containers
@@ -433,6 +433,8 @@ stages:
433433
'
434434
fi
435435
436+
# Avoid accumulating six copies of the test tree on emulated ARM64 jobs.
437+
docker exec build-$(LINUX_TAG)-$(ARCH) $SHELL_EXE -lc "rm -rf /test_isolated_${PYBIN}"
436438
echo "✓ Build and test complete for $PYBIN"
437439
done
438440
@@ -448,7 +450,7 @@ stages:
448450
- script: |
449451
set -euo pipefail
450452
451-
# Copy all wheels (5 Python versions) to output directory
453+
# Copy all wheels (6 Python versions) to output directory
452454
echo "Copying wheels to host..."
453455
docker cp build-$(LINUX_TAG)-$(ARCH):/workspace/dist/. "$(ob_outputDirectory)/wheels/" || echo "No wheels found"
454456

‎OneBranchPipelines/stages/build-macos-single-stage.yml‎

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,13 @@ stages:
9191
# =========================
9292
# BUILD TOOLS
9393
# =========================
94-
# CMake = cross-platform build system generator (needed for C++ compilation)
95-
# Uninstall first to ensure clean version (avoid conflicts with pre-installed CMake)
94+
# Install all Homebrew tooling in one transaction, matching PR validation.
95+
# Do not run brew update: hosted runners already provide bottle metadata,
96+
# while updating can select formulae that compile Go and Lima from source.
9697
- script: |
97-
brew update
9898
brew uninstall cmake --ignore-dependencies || echo "CMake not installed"
99-
brew install cmake
100-
displayName: 'Install CMake'
99+
brew install cmake docker colima
100+
displayName: 'Install build & container tooling (Homebrew)'
101101
102102
# =========================
103103
# PYTHON DEPENDENCIES
@@ -133,22 +133,15 @@ stages:
133133
TargetFolder: '$(ob_outputDirectory)/bindings/macOS'
134134
displayName: 'Copy .so files'
135135

136-
# Install Docker CLI and Colima (macOS Docker runtime)
136+
# Start Colima (macOS Docker runtime). Tooling is installed above so the
137+
# 15-minute timeout covers only VM startup, not Homebrew compilation.
137138
# Colima = lightweight Docker Desktop alternative using macOS virtualization
138-
# vz = native macOS virtualization (faster, only works on M1+)
139-
# qemu = cross-platform emulator (slower, works on Intel Macs)
140139
# 4 CPU cores + 8GB RAM needed for SQL Server container
141140
- script: |
142-
brew update
143-
brew install docker colima
144-
colima start --vm-type vz --cpu 4 --memory 8 || {
145-
echo "vz VM failed, trying qemu..."
146-
colima start --vm-type qemu --cpu 4 --memory 8
147-
}
148-
sleep 30
141+
colima start --cpu 4 --memory 8 --disk 50
149142
docker context use colima >/dev/null || true
150143
docker version
151-
displayName: 'Install and start Docker (Colima)'
144+
displayName: 'Start Docker (Colima)'
152145
timeoutInMinutes: 15
153146
154147
# =========================

0 commit comments

Comments
 (0)