Skip to content

Commit

Permalink
Set concurrency groups in CI workflows
Browse files Browse the repository at this point in the history
Disable old actions that stay in one PR or github-reference(branch/tag).
Refactor cibuildwheel job.
  • Loading branch information
Vdaleke authored and chernishev committed Feb 1, 2025
1 parent f2c430b commit 4528a33
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 2 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/bindings-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,16 @@ on:
- build.*
- pull_datasets.sh
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
# Cancel in-progress runs when a new workflow with the same group name is triggered
cancel-in-progress: true

jobs:
test-python-bindings:
name: Run python-bindings tests on ${{ matrix.os }} with ${{ matrix.toolset }}
continue-on-error: true
strategy:
matrix:
include:
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/check-codestyle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,15 @@ on:
- build.*
- pull_datasets.sh
- pyproject.toml

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
# Cancel in-progress runs when a new workflow with the same group name is triggered
cancel-in-progress: true

jobs:
clang-format-check:
continue-on-error: true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/core-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,16 @@ on:
#- pyproject.toml
#- examples/**
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
# Cancel in-progress runs when a new workflow with the same group name is triggered
cancel-in-progress: true

jobs:
run_tests:
name: Run core-tests on ${{ matrix.system.os }} with ${{ matrix.system.toolset }}, ${{matrix.cfg.BUILD_TYPE}} ${{ matrix.cfg.SANITIZER }}
continue-on-error: true
strategy:
matrix:
system:
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ on:
release:
types:
- published

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
# Cancel in-progress runs when a new workflow with the same group name is triggered
cancel-in-progress: true

jobs:
generate-linux-wheels-matrix:
name: Generate Linux wheel matrix
Expand Down Expand Up @@ -150,15 +156,15 @@ jobs:
export BOOST_ROOT=/usr/local &&
export CXX=clang++ &&
export DYLD_LIBRARY_PATH=/usr/local/lib:${DYLD_LIBRARY_PATH}
CIBW_REPAIR_WHEEL_COMMAND_MACOS: >
DYLD_LIBRARY_PATH=/usr/local/lib:${DYLD_LIBRARY_PATH} delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel}
CIBW_TEST_COMMAND: >
cp {project}/test_input_data/WDC_satellites.csv {project}/src/python_bindings &&
cp {project}/test_input_data/transactional_data/rules-kaggle-rows.csv {project}/src/python_bindings &&
cp {project}/test_input_data/TestLong.csv {project}/src/python_bindings &&
cp {project}/test_input_data/TestWide.csv {project}/src/python_bindings &&
cd {project}/src/python_bindings &&
python3 {project}/src/python_bindings/test_bindings.py
CIBW_REPAIR_WHEEL_COMMAND_MACOS: >
DYLD_LIBRARY_PATH=/usr/local/lib:${DYLD_LIBRARY_PATH} delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel}
- name: Upload artifact
uses: actions/upload-artifact@v4
Expand Down

0 comments on commit 4528a33

Please sign in to comment.