Skip to content

Commit bbe3c79

Browse files
committed
Try Windows using conda
1 parent 91acf11 commit bbe3c79

File tree

3 files changed

+14
-16
lines changed

3 files changed

+14
-16
lines changed

.github/workflows/python.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,11 +288,23 @@ jobs:
288288
env:
289289
# We can invalidate the current cache by updating this.
290290
CACHE_VERSION: "2025-09-16.1"
291+
- name: Install and setup micromamba
292+
shell: cmd
293+
env:
294+
MAMBA_ROOT_PREFIX: "C:\\micromamba"
295+
run: |
296+
curl -L -o micromamba.tar.bz2 https://micro.mamba.pm/api/micromamba/win-64/latest
297+
tar xf micromamba.tar.bz2
298+
mv "Library\bin\micromamba.exe" micromamba.exe
299+
.\micromamba.exe shell init -s cmd -r %MAMBA_ROOT_PREFIX%
300+
micromamba create -n pyarrow-dev -f ".\ci\conda_env_python.txt" -y
291301
- name: Build Arrow C++ and PyArrow
292302
shell: cmd
293303
run: |
294-
call "ci\scripts\python_build.bat" %cd% "${{ steps.path-info.outputs.usr-windows-dir }}"
304+
micromamba activate pyarrow-dev
305+
call "ci\scripts\python_build.bat" %cd% %CONDA_PREFIX%
295306
- name: Test PyArrow
296307
shell: cmd
297308
run: |
309+
micromamba activate pyarrow-dev
298310
call "ci\scripts\python_test.bat" %cd%

ci/scripts/python_build.bat

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -198,15 +198,9 @@ pushd %SOURCE_DIR%\python
198198
@REM Install Python build dependencies
199199
%PYTHON_CMD% -m pip install --upgrade pip || exit /B 1
200200
%PYTHON_CMD% -m pip install -r requirements-build.txt || exit /B 1
201-
%PYTHON_CMD% -m pip install build delvewheel || exit /B 1
202-
203-
@REM by default, CMake installs .lib import libs to lib and .dll libs to bin
204-
@REM delvewheel requires these to be side-by-side to properly vendor
205-
@REM https://github.com/adang1345/delvewheel/issues/66
206-
copy %CMAKE_INSTALL_PREFIX%\lib\*.lib %CMAKE_INSTALL_PREFIX%\bin\
207201

208202
@REM Build PyArrow
209-
%PYTHON_CMD% -m build --wheel . --no-isolation ^
203+
%PYTHON_CMD% -m pip install --no-deps --no-build-isolation -vv . ^
210204
-Csetup-args="-Dbuildtype=%MESON_BUILD_TYPE%" ^
211205
-Csetup-args="-Dacero=%PYARROW_WITH_ACERO%" ^
212206
-Csetup-args="-Ddataset=%PYARROW_WITH_DATASET%" ^
@@ -219,7 +213,5 @@ copy %CMAKE_INSTALL_PREFIX%\lib\*.lib %CMAKE_INSTALL_PREFIX%\bin\
219213
-Csetup-args="-Dparquet_require_encryption=%PYARROW_WITH_PARQUET_ENCRYPTION%" ^
220214
-Csetup-args="-Dsubstrait=%PYARROW_WITH_SUBSTRAIT%" ^
221215
-Csetup-args="-Ds3=%PYARROW_WITH_S3%" || exit /B 1
222-
%PYTHON_CMD% -m delvewheel repair --ignore-existing --no-mangle-all --include-imports dist\* || exit /B 1
223-
%PYTHON_CMD% -m pip install --no-index --find-links .\wheelhouse\ pyarrow || exit /B 1
224216

225217
popd

python/pyarrow/__init__.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -393,12 +393,6 @@ def get_library_dirs():
393393
package_cwd = _os.path.dirname(__file__)
394394
library_dirs = [package_cwd]
395395

396-
# delvewheel creates a top level pyarrow.libs to vendor external shared libraries
397-
if _os.name == "nt":
398-
library_dirs.append(
399-
_os.path.join(_os.path.dirname(package_cwd), "pyarrow.libs")
400-
)
401-
402396
def append_library_dir(library_dir):
403397
if library_dir not in library_dirs:
404398
library_dirs.append(library_dir)

0 commit comments

Comments
 (0)