Add Windows ARM64 support to CI - #1846
chinazhangchao wants to merge 4 commits into
Conversation
|
@chinazhangchao Skipping tests would be a bad idea. You can install PostgreSQL on the WoA runners like I have done in this PR: psycopg/psycopg#1385 |
|
Could you please help to review? Thanks. Chao |
Is there a reason for using PostgreSQL 17 on Windows ARM when the existing Linux test jobs use postgres:16? If PostgreSQL is only a test fixture, should the ARM job use a pinned PostgreSQL 16 package for consistency, or is the additional PostgreSQL 17 coverage intentional?
This job builds and uploads wheels, so its downloaded dependencies and failure behaviour should be deterministic. That being said, I am not a maintainer of |
Thanks for the detailed review. PostgreSQL 17 was not intentional, so I aligned the Windows ARM64 job with the existing PostgreSQL 16 test fixture. The Chocolatey package is now pinned to |
Hi @dvarrazzo , I'm from Microsoft and recently I'm working on improving Python ecosystem support for Windows on Arm.
So I updates the CI workflows to add support for Windows ARM64 builds and tests. Could you please help to review? Thanks.
Test results:
https://github.com/chinazhangchao/psycopg2/actions/runs/32325062129
Windows ARM64 support and workflow updates:
windowsjob in.github/workflows/packages.ymlto addwin_arm64to the build matrix, conditionally select the appropriate runner image, and exclude unsupported Python versions for ARM64.arm64-windowsfor ARM64,x64-windows-releasefor AMD64) and setCIBW_ARCHS_WINDOWSaccordingly. [1] [2]Build script improvements:
scripts/build/wheel_win32_before_build.batto setVCPKG_TARGET_TRIPLETbased on architecture and install the correctlibpqpackage for each triplet.Stub script enhancements:
pg_config_vcpkg_stubto support both AMD64 and ARM64, checking the platform and triplet, and constructing the vcpkg path dynamically. The documentation was also updated to reflect the new usage. [1] [2]