@@ -34,12 +34,31 @@ RUN (if "%python%"=="3.10" setx PYTHON_VERSION "3.10.11" && setx PYTHON_CMD "py
3434 (if "%python%" =="3.13" setx PYTHON_VERSION "3.13.7" && setx PYTHON_CMD "py -3.13" ) & \
3535 (if "%python%" =="3.14" setx PYTHON_VERSION "3.14.0" && setx PYTHON_CMD "py -3.14" )
3636
37+ SHELL ["powershell" , "-NoProfile" , "-Command" , "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';" ]
38+ # Install Python install manager (MSIX)
39+ RUN $msix_url = 'https://www.python.org/ftp/python/installer/python.msix' ; \
40+ Invoke-WebRequest -Uri $msix_url -OutFile 'python.msix' ; \
41+ Add-AppxPackage .\p ython.msix
42+
43+ # Use python_abi_tag env var to select regular or free-threaded Python
44+ ARG freethreaded=0
45+ ENV PYTHON_MODE=${freethreaded}
46+ RUN if ($env:PYTHON_MODE -eq '1' ) { \
47+ pymanager install --version $env:PYTHON_VERSION --variant freethreaded \
48+ } else { \
49+ pymanager install --version $env:PYTHON_VERSION \
50+ }
51+
52+ SHELL ["cmd" , "/S" , "/C" ]
3753# hadolint ignore=DL3059
38- RUN choco install -r -y --pre --no-progress --force python --version=%PYTHON_VERSION%
39- # hadolint ignore=DL3059
40- RUN %PYTHON_CMD% -m pip install -U pip setuptools
54+ RUN %PYTHON_CMD% -m pip install -U pip setuptools & \
55+ if "%python%" =="3.13" ( \
56+ setx REQUIREMENTS_FILE "requirements-wheel-test-3.13t.txt" \
57+ ) else ( \
58+ setx REQUIREMENTS_FILE "requirements-wheel-test.txt" \
59+ )
4160
42- COPY python/requirements-wheel-test.txt C:/arrow/python/
43- RUN %PYTHON_CMD% -m pip install -r C:/arrow/python/requirements-wheel-test.txt
61+ COPY python/requirements-wheel-test-3.13t.txt python/requirements-wheel-test .txt C:/arrow/python/
62+ RUN %PYTHON_CMD% -m pip install -r C:/arrow/python/%REQUIREMENTS_FILE%
4463
4564ENV PYTHON=$python
0 commit comments