3737import json
3838import logging
3939import os
40+ import platform
4041import shutil
42+ import subprocess
4143import sys
4244import time
4345from datetime import UTC , datetime
@@ -677,6 +679,33 @@ def _get_provider_cwd() -> str:
677679 return str (module_root )
678680
679681
682+ # ═══════════════════════════════════════════════════════════════════════════════
683+ # WINDOWS ARM64 SKIP — Class-Level
684+ # ═══════════════════════════════════════════════════════════════════════════════
685+ # Amplifier's bundle preparation tries to install `tool-mcp` module which
686+ # depends on `cryptography` via the dependency chain:
687+ # tool-mcp → mcp → pyjwt[crypto] → cryptography
688+ #
689+ # On Windows ARM64, `cryptography` has no pre-built wheel and requires Rust
690+ # to compile from source. The build fails with:
691+ # "Unsupported platform: win_arm64"
692+ #
693+ # This causes Amplifier's bundle prep to hang for ~30 seconds attempting
694+ # the build, which exhausts the Copilot SDK's internal ping() timeout
695+ # (also 30s), resulting in TimeoutError during client initialization.
696+ #
697+ # This is NOT a provider bug - it's a platform limitation. The raw SDK
698+ # works perfectly on Windows ARM64 when tested in isolation.
699+ #
700+ # Windows x64 DOES work because cryptography has pre-built wheels for x64.
701+ # ═══════════════════════════════════════════════════════════════════════════════
702+ @pytest .mark .skipif (
703+ platform .system () == "Windows" and platform .machine () in ("ARM64" , "aarch64" ),
704+ reason = (
705+ "Amplifier's tool-mcp module requires cryptography which has no ARM64 wheel. "
706+ "This test passes on Windows x64, Linux, and macOS."
707+ ),
708+ )
680709class TestAmplifierEndToEnd :
681710 """
682711 Full end-to-end tests that invoke Amplifier CLI and verify
@@ -688,6 +717,12 @@ class TestAmplifierEndToEnd:
688717 Prerequisites:
689718 - Amplifier CLI installed via 'uv tool install' and on PATH
690719 - Copilot provider configured in Amplifier
720+
721+ Platform Notes:
722+ - Windows x64: ✓ Works (cryptography has pre-built wheels)
723+ - Windows ARM64: ✗ Skipped (no cryptography wheel, see class decorator)
724+ - Linux/WSL: ✓ Works
725+ - macOS: ✓ Works
691726 """
692727
693728 @pytest .mark .asyncio
@@ -697,43 +732,7 @@ async def test_amplifier_simple_math(self) -> None:
697732
698733 This is a smoke test that validates Amplifier can use the Copilot
699734 provider without errors.
700-
701- Platform Notes:
702- - Windows x64: ✓ Works fine (cryptography has pre-built wheels)
703- - Windows ARM64: ✗ Skipped (see skip condition below)
704- - Linux/WSL: ✓ Works fine
705- - macOS: ✓ Works fine
706735 """
707- import platform
708- import subprocess
709-
710- # ═══════════════════════════════════════════════════════════════════════════
711- # WINDOWS ARM64 SKIP EXPLANATION
712- # ═══════════════════════════════════════════════════════════════════════════
713- # Amplifier's bundle preparation tries to install `tool-mcp` module which
714- # depends on `cryptography` via the dependency chain:
715- # tool-mcp → mcp → pyjwt[crypto] → cryptography
716- #
717- # On Windows ARM64, `cryptography` has no pre-built wheel and requires Rust
718- # to compile from source. The build fails with:
719- # "Unsupported platform: win_arm64"
720- #
721- # This causes Amplifier's bundle prep to hang for ~30 seconds attempting
722- # the build, which exhausts the Copilot SDK's internal ping() timeout
723- # (also 30s), resulting in TimeoutError during client initialization.
724- #
725- # This is NOT a provider bug - it's a platform limitation. The raw SDK
726- # works perfectly on Windows ARM64 when tested in isolation.
727- #
728- # Windows x64 DOES work because cryptography has pre-built wheels for x64.
729- # ═══════════════════════════════════════════════════════════════════════════
730- if platform .system () == "Windows" and platform .machine () in ("ARM64" , "aarch64" ):
731- pytest .skip (
732- "Skipping on Windows ARM64: Amplifier's tool-mcp module requires "
733- "cryptography which has no ARM64 wheel (needs Rust to build). "
734- "This test passes on Windows x64, Linux, and macOS."
735- )
736-
737736 amplifier_bin = _find_amplifier_cli ()
738737 if not amplifier_bin :
739738 pytest .skip (
@@ -777,43 +776,7 @@ async def test_amplifier_bug_hunter_delegation(self) -> None:
777776
778777 This is the definitive proof that the SDK Driver architecture
779778 fixes the 305-turn loop.
780-
781- Platform Notes:
782- - Windows x64: ✓ Works fine (cryptography has pre-built wheels)
783- - Windows ARM64: ✗ Skipped (see skip condition below)
784- - Linux/WSL: ✓ Works fine
785- - macOS: ✓ Works fine
786779 """
787- import platform
788- import subprocess
789-
790- # ═══════════════════════════════════════════════════════════════════════════
791- # WINDOWS ARM64 SKIP EXPLANATION
792- # ═══════════════════════════════════════════════════════════════════════════
793- # Amplifier's bundle preparation tries to install `tool-mcp` module which
794- # depends on `cryptography` via the dependency chain:
795- # tool-mcp → mcp → pyjwt[crypto] → cryptography
796- #
797- # On Windows ARM64, `cryptography` has no pre-built wheel and requires Rust
798- # to compile from source. The build fails with:
799- # "Unsupported platform: win_arm64"
800- #
801- # This causes Amplifier's bundle prep to hang for ~30 seconds attempting
802- # the build, which exhausts the Copilot SDK's internal ping() timeout
803- # (also 30s), resulting in TimeoutError during client initialization.
804- #
805- # This is NOT a provider bug - it's a platform limitation. The raw SDK
806- # works perfectly on Windows ARM64 when tested in isolation.
807- #
808- # Windows x64 DOES work because cryptography has pre-built wheels for x64.
809- # ═══════════════════════════════════════════════════════════════════════════
810- if platform .system () == "Windows" and platform .machine () in ("ARM64" , "aarch64" ):
811- pytest .skip (
812- "Skipping on Windows ARM64: Amplifier's tool-mcp module requires "
813- "cryptography which has no ARM64 wheel (needs Rust to build). "
814- "This test passes on Windows x64, Linux, and macOS."
815- )
816-
817780 amplifier_bin = _find_amplifier_cli ()
818781 if not amplifier_bin :
819782 pytest .skip (
0 commit comments