From 0ec9edcaad19b71d06fbbfb100b9366ce088530f Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Sat, 30 Sep 2023 18:12:07 +0200 Subject: [PATCH] Fix fuzzy testing (#70) --- .github/workflows/fuzzy-testing.yml | 40 ++++++++++++++++++++--------- 1 file changed, 28 insertions(+), 12 deletions(-) diff --git a/.github/workflows/fuzzy-testing.yml b/.github/workflows/fuzzy-testing.yml index 8cf96885..e29c9cd2 100644 --- a/.github/workflows/fuzzy-testing.yml +++ b/.github/workflows/fuzzy-testing.yml @@ -8,29 +8,20 @@ on: branches: [ main ] paths: - ".github/workflows/fuzzy-testing.yml" - - "bindings/python/**" - "cmake/**" - - "examples/**" - "src/**" - "test/scripts/fuzzy_test.py" - "test/scripts/link_h5_dataset.py" - "CMakeLists.txt" - "conanfile.txt" - - "pyproject.toml" - - "setup.cfg" - - "setup.py" tags: - 'v*.*.*' pull_request: paths: - ".github/workflows/fuzzy-testing.yml" - - "bindings/python/**" - "test/scripts/fuzzy_test.py" - "test/scripts/link_h5_dataset.py" - - "pyproject.toml" - - "setup.cfg" - - "setup.py" schedule: # Run weekly @@ -112,6 +103,9 @@ jobs: CONAN_HOME: '/root/.conan2' steps: + - name: Clone hictk + uses: actions/checkout@v4 + - name: Clone hictkpy uses: actions/checkout@v4 with: @@ -127,7 +121,7 @@ jobs: sed -i 's|URL_HASH.*|GIT_TAG ${{ github.event.after }}|' CMakeLists.txt grep 'GIT_TAG' CMakeLists.txt - - name: Patch hictkpy + - name: Patch hictkpy (schedule) working-directory: hictkpy if: github.event_name == 'schedule' run: | @@ -166,6 +160,28 @@ jobs: conan cache clean "*" --source conan remove --confirm "*" + - name: Install build dependencies + run: | + conan install . \ + --build=missing \ + -pr:b="$CONAN_DEFAULT_PROFILE_PATH" \ + -pr:h="$CONAN_DEFAULT_PROFILE_PATH" \ + -s build_type=Release \ + -s compiler.libcxx=libstdc++11 \ + -s compiler.cppstd=17 \ + -o '*/*:shared=True' \ + --output-folder=build + + conan install hictkpy \ + --build=missing \ + -pr:b="$CONAN_DEFAULT_PROFILE_PATH" \ + -pr:h="$CONAN_DEFAULT_PROFILE_PATH" \ + -s build_type=Release \ + -s compiler.libcxx=libstdc++11 \ + -s compiler.cppstd=17 \ + -o '*/*:shared=True' \ + --output-folder=build + - name: Clean Conan cache (post-build) if: steps.cache-conan.outputs.cache-hit != 'true' run: | @@ -173,14 +189,14 @@ jobs: conan cache clean "*" --download conan cache clean "*" --source - - name: Install Python bindings working-directory: hictkpy run: | pip install --upgrade pip setuptools wheel pybind11 env CC=clang-15 \ CXX=clang++-15 \ - CMAKE_ARGS="-DCMAKE_PREFIX_PATH=$PWD/build" \ + CMAKE_ARGS="-DCMAKE_PREFIX_PATH=$PWD/../build" \ + HICTKPY_SETUP_SKIP_CONAN=1 \ pip install . -v - name: Save Conan cache