Python bindings for index writer #57
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run tests | |
on: | |
push: | |
branches: ['main'] | |
pull_request: | |
jobs: | |
build_w_submodules: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Set up Apache Arrow repositories | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y ca-certificates lsb-release wget | |
wget https://apache.jfrog.io/artifactory/arrow/$(lsb_release --id --short | tr 'A-Z' 'a-z')/apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb | |
sudo apt-get install -y ./apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb | |
sudo apt-get update | |
- name: Install build dependencies | |
run: | | |
sudo apt-get install -y cmake g++ libhdf5-openmpi-dev librange-v3-dev ninja-build nlohmann-json3-dev | |
sudo apt-get install -y libarrow-dev libparquet-dev | |
sudo apt-get install -y python3 python3-dev python3-pip | |
sudo apt-get install -y openmpi-bin libopenmpi-dev | |
pip3 install nanobind mpi4py h5py | |
- name: Configure and build | |
run: | | |
cmake -B build -S . -GNinja \ | |
-DCMAKE_INSTALL_PREFIX=$PWD/install \ | |
-DCMAKE_CXX_COMPILER=$(which mpicxx) | |
cmake --build build | |
ctest --test-dir build --output-on-failure | |
cmake --install build | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
- name: Small integration test (excluding MPI test) | |
run: | | |
export PATH=$PATH:$PWD/install/bin | |
export PYTHONPATH=$PYTHONPATH:$PWD/build | |
python -mpip install -r tests/test_requirements.txt | |
python -mpytest tests -k "not test_indexing" | |
- name: Run MPI test | |
run: PYTHONPATH=$PYTHONPATH:$PWD/build PATH=$PATH:$PWD/install/bin mpirun -n 2 --oversubscribe python -mpytest tests/test_indexing.py | |
build_docker_no_submodules: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Build | |
uses: docker/build-push-action@v5 |