From ad128fc1e93f13a2438f62be43f9e0e8e9667a1a Mon Sep 17 00:00:00 2001 From: Charlier Benjamin Date: Wed, 30 Oct 2024 10:44:22 +0100 Subject: [PATCH 1/6] remove cirrus ci. Add macOs and ubuntu to github-actions --- .cirrus.yml | 20 ------------- .github/workflows/cuda_test.yml | 15 ---------- .github/workflows/{black.yml => lint.yml} | 2 +- .github/workflows/test.yml | 36 +++++++++++++++++++++++ 4 files changed, 37 insertions(+), 36 deletions(-) delete mode 100644 .cirrus.yml delete mode 100644 .github/workflows/cuda_test.yml rename .github/workflows/{black.yml => lint.yml} (87%) create mode 100644 .github/workflows/test.yml diff --git a/.cirrus.yml b/.cirrus.yml deleted file mode 100644 index 9e2e27f40..000000000 --- a/.cirrus.yml +++ /dev/null @@ -1,20 +0,0 @@ -task: - name: Tests (linux) - container: - image: ubuntu:latest - install_script: - - apt-get update - - apt-get -y install python3 python3-venv python3-dev g++ - test_script: - - bash ./pytest.sh - - -task: - name: Tests (macOS) - macos_instance: - image: ghcr.io/cirruslabs/macos-ventura-xcode:latest - script: - - sh ./pytest.sh - - - diff --git a/.github/workflows/cuda_test.yml b/.github/workflows/cuda_test.yml deleted file mode 100644 index 1d727b2f1..000000000 --- a/.github/workflows/cuda_test.yml +++ /dev/null @@ -1,15 +0,0 @@ -# Launch test on a cuda machine -name: Cuda test - -on: - push - -jobs: - test: - runs-on: self-hosted - steps: - - name: Clone Repository - uses: actions/checkout@v2 - - name: Test with pytest - run: | - sh ./pytest.sh diff --git a/.github/workflows/black.yml b/.github/workflows/lint.yml similarity index 87% rename from .github/workflows/black.yml rename to .github/workflows/lint.yml index 69934f854..686473ec3 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/lint.yml @@ -1,6 +1,6 @@ name: Lint -on: [push, pull_request] +on: [pull_request] jobs: lint: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 000000000..5568639ad --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,36 @@ +# Launch test on various platforms +name: Test + +on: + pull_request_target: + types: [opened, synchronize, reopened, closed] + branches: ['main'] + workflow_dispatch: + +jobs: + test-self-hosted: + runs-on: self-hosted + steps: + - name: Clone Repository + uses: actions/checkout@v2 + - name: Test with pytest + run: | + sh ./pytest.sh + + test-ubuntu: + runs-on: ubuntu-latest + steps: + - name: Clone Repository + uses: actions/checkout@v2 + - name: Test with pytest + run: | + sh ./pytest.sh + + test-macos: + runs-on: macOS-latest + steps: + - name: Clone Repository + uses: actions/checkout@v2 + - name: Test with pytest + run: | + sh ./pytest.sh From 7a5bc48fddafb8dd4b85e6970b98fe48eca544ea Mon Sep 17 00:00:00 2001 From: bcharlier Date: Wed, 30 Oct 2024 10:57:49 +0100 Subject: [PATCH 2/6] Update test.yml --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5568639ad..d57d5bdf4 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,7 +5,7 @@ on: pull_request_target: types: [opened, synchronize, reopened, closed] branches: ['main'] - workflow_dispatch: + jobs: test-self-hosted: From 039eede56cf4e1a3feeed830c75a9f49362bea18 Mon Sep 17 00:00:00 2001 From: bcharlier Date: Wed, 30 Oct 2024 11:00:23 +0100 Subject: [PATCH 3/6] Update test.yml --- .github/workflows/test.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d57d5bdf4..ae67d5a7d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,11 +1,7 @@ # Launch test on various platforms name: Test -on: - pull_request_target: - types: [opened, synchronize, reopened, closed] - branches: ['main'] - +on: [pull_request, workflow_dispatch] jobs: test-self-hosted: From ae11172ae97135a5a6293724ced718cfd388f137 Mon Sep 17 00:00:00 2001 From: bcharlier Date: Wed, 30 Oct 2024 11:03:24 +0100 Subject: [PATCH 4/6] Update test.yml --- .github/workflows/test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ae67d5a7d..ba2bc01f8 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,7 +20,7 @@ jobs: uses: actions/checkout@v2 - name: Test with pytest run: | - sh ./pytest.sh + bash ./pytest.sh test-macos: runs-on: macOS-latest @@ -29,4 +29,4 @@ jobs: uses: actions/checkout@v2 - name: Test with pytest run: | - sh ./pytest.sh + bash ./pytest.sh From d2dc065285794f2d2da531f26938cd783793d866 Mon Sep 17 00:00:00 2001 From: bcharlier Date: Wed, 30 Oct 2024 11:09:53 +0100 Subject: [PATCH 5/6] Update test.yml --- .github/workflows/test.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ba2bc01f8..4bba97ac5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,6 +25,10 @@ jobs: test-macos: runs-on: macOS-latest steps: + - name: Set up Python 3.12 + uses: actions/setup-python@v4 + with: + python-version: 3.12 - name: Clone Repository uses: actions/checkout@v2 - name: Test with pytest From 9c9ae8de32ff132c6adbf75a17251f41c40a5dd3 Mon Sep 17 00:00:00 2001 From: Charlier Benjamin Date: Wed, 30 Oct 2024 14:51:52 +0100 Subject: [PATCH 6/6] add ubuntu cpu runner. Remove self hosted runner. --- .github/workflows/test.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4bba97ac5..288c10d81 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -4,21 +4,23 @@ name: Test on: [pull_request, workflow_dispatch] jobs: - test-self-hosted: - runs-on: self-hosted + test-ubuntu-gpu: + runs-on: ubuntu-latest steps: - name: Clone Repository uses: actions/checkout@v2 - name: Test with pytest run: | - sh ./pytest.sh + bash ./pytest.sh - test-ubuntu: + test-ubuntu-cpu: runs-on: ubuntu-latest steps: - name: Clone Repository uses: actions/checkout@v2 - name: Test with pytest + env: + CUDA_VISIBLE_DEVICES: -1 run: | bash ./pytest.sh