From 9f039659e9d28a04644c8a481cf5b6683faa9bcc Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:25:16 +0100 Subject: [PATCH 01/40] Do not run tests if branch is not up to date with main --- .github/workflows/integration_tests_inference_cli_x86.yml | 6 ++++++ .github/workflows/integration_tests_inference_models.yml | 6 ++++++ .../workflows/integration_tests_inference_server_x86.yml | 6 ++++++ .github/workflows/integration_tests_workflows_x86.yml | 6 ++++++ .github/workflows/test_package_install_inference.yml | 6 ++++++ .github/workflows/test_package_install_inference_cli.yml | 6 ++++++ .github/workflows/test_package_install_inference_gpu.yml | 6 ++++++ .../test_package_install_inference_gpu_with_extras.yml | 6 ++++++ .github/workflows/test_package_install_inference_sdk.yml | 6 ++++++ .../test_package_install_inference_with_extras.yml | 6 ++++++ .github/workflows/unit_tests_inference_cli_x86.yml | 6 ++++++ .github/workflows/unit_tests_inference_sdk_x86.yml | 6 ++++++ .github/workflows/unit_tests_inference_x86.yml | 6 ++++++ .github/workflows/unit_tests_workflows_x86.yml | 6 ++++++ 14 files changed, 84 insertions(+) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index a28a714c3..b37850b96 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index e206cb77c..395d32ff8 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 252b0939e..b4fbcec29 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -26,6 +26,12 @@ jobs: uses: actions/checkout@v3 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🦾 Install dependencies run: | diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 9e0b09a9e..151f2efc0 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run tests since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index fc6d6dc32..3a2923447 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 4449bd198..cf76ca58e 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 3392b1cd6..0e31c56ce 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 27c210e76..a14a71efa 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 721c6342e..2d84c0626 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 9476cd097..2f25790c6 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -22,6 +22,12 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 1d41295d4..5d4f7df89 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 66aea941f..3bccf9526 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 8fce63108..16137f40d 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index ddbb6deb8..81f8ec692 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -21,6 +21,12 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + - name: Fail if branch is not up to date with main + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "Refusing to run test since this branch is not up to date with main."; + exit 1; + fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: From d93e21e82b4db7209a9a1257a2236d9f963e4cf5 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:32:11 +0100 Subject: [PATCH 02/40] syntax --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 4 ++-- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 14 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index b37850b96..1b7ea077a 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 395d32ff8..d7f621c96 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index b4fbcec29..4bae24c50 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -28,7 +28,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 151f2efc0..541565263 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -23,8 +23,8 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then - echo "Refusing to run tests since this branch is not up to date with main."; + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then + echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi - name: 🐍 Set up Python ${{ matrix.python-version }} diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 3a2923447..7b3a95778 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index cf76ca58e..de560fdc8 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 0e31c56ce..f73d2e607 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index a14a71efa..a6a1c4c8c 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 2d84c0626..877e1c747 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 2f25790c6..c59bb48df 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 5d4f7df89..7ce173e54 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 3bccf9526..91e994f67 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 16137f40d..aaaf34ed4 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 81f8ec692..caf9180f4 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -23,7 +23,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fail if branch is not up to date with main run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then echo "Refusing to run test since this branch is not up to date with main."; exit 1; fi From 5297403b2444323bef22526c756364123c4bc147 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:40:04 +0100 Subject: [PATCH 03/40] test --- .github/workflows/test_package_install_inference_cli.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index de560fdc8..632939804 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: From b5a3bd94ba608c2a1c3aa2496bf1e51cc433ef72 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:45:37 +0100 Subject: [PATCH 04/40] skip instead of failing --- .github/workflows/integration_tests_inference_cli_x86.yml | 7 +------ .github/workflows/integration_tests_inference_models.yml | 7 +------ .../workflows/integration_tests_inference_server_x86.yml | 8 +------- .github/workflows/integration_tests_workflows_x86.yml | 7 +------ .github/workflows/test_package_install_inference.yml | 7 +------ .github/workflows/test_package_install_inference_gpu.yml | 7 +------ .../test_package_install_inference_gpu_with_extras.yml | 7 +------ .github/workflows/test_package_install_inference_sdk.yml | 7 +------ .../test_package_install_inference_with_extras.yml | 7 +------ .github/workflows/unit_tests_inference_cli_x86.yml | 7 +------ .github/workflows/unit_tests_inference_sdk_x86.yml | 7 +------ .github/workflows/unit_tests_inference_x86.yml | 7 +------ .github/workflows/unit_tests_workflows_x86.yml | 7 +------ 13 files changed, 13 insertions(+), 79 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 1b7ea077a..e745a777b 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index d7f621c96..49ce09cdf 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 4bae24c50..6caa7cc74 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,6 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} + if: ${{ github.ref == 'refs/heads/main' }} runs-on: group: group8core timeout-minutes: 35 @@ -26,13 +27,6 @@ jobs: uses: actions/checkout@v3 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - - name: 🦾 Install dependencies run: | python -m pip install --upgrade pip diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 541565263..13b9227d4 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 7b3a95778..2e075f0c5 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index f73d2e607..7f3748616 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index a6a1c4c8c..6b86af555 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 877e1c747..65261442e 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index c59bb48df..ac470888b 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -12,6 +12,7 @@ permissions: jobs: build: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -22,12 +23,6 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 🐍 Set up Python 3.9 to create wheels uses: actions/setup-python@v2 with: diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 7ce173e54..38b99fa8f 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 91e994f67..30095cef7 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index aaaf34ed4..55285874d 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index caf9180f4..8968b55f6 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -9,6 +9,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot @@ -21,12 +22,6 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} - - name: Fail if branch is not up to date with main - run: | - if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}; then - echo "Refusing to run test since this branch is not up to date with main."; - exit 1; - fi - name: 📦 Cache Python packages uses: actions/cache@v3 with: From a7e77ce4a7765f655811a0dcb5d5721189b6fa12 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:47:17 +0100 Subject: [PATCH 05/40] Skip static code analysis --- .github/workflows/static_code_analysis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index b815862de..03f85af78 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,6 +8,7 @@ on: jobs: build-dev-test: + if: ${{ github.ref == 'refs/heads/main' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot From 2c7f5fd18f3f275c33ab87b3d68f0164bf749e24 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 10:58:40 +0100 Subject: [PATCH 06/40] fix --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index e745a777b..ee161ca1c 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 49ce09cdf..4c2e55239 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 6caa7cc74..720b4cfe3 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,7 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 13b9227d4..9d5b54c7c 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 03f85af78..eaa7ecf4a 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,7 +8,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 2e075f0c5..2bef0341f 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 632939804..0c4218452 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 7f3748616..27be34e11 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 6b86af555..63775ea6a 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 65261442e..2a1287b15 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index ac470888b..a6d7b37a5 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 38b99fa8f..98ded29d7 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 30095cef7..fc314e9be 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 55285874d..04192c86a 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 8968b55f6..d3790ab73 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.ref == 'refs/heads/main' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From f021b7ee7c42bf5882ac416231ebec9e0d5984cf Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 11:03:17 +0100 Subject: [PATCH 07/40] test --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index ee161ca1c..35180f40d 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 4c2e55239..9d13d0b7f 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 720b4cfe3..bbf13b7f8 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,7 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 9d5b54c7c..6b8b07a33 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index eaa7ecf4a..e886cffcc 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,7 +8,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 2bef0341f..a28b71bd2 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 0c4218452..2ceecbaf8 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 27be34e11..790abfcc7 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 63775ea6a..48f2083bd 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 2a1287b15..a893cde72 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index a6d7b37a5..663c3044c 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 98ded29d7..7e031258c 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index fc314e9be..98607bc02 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 04192c86a..877b701a5 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index d3790ab73..3bef98a90 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.base_sha }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From 718f7e15b3d1a6d4375e0c13f3f6c7900397c1c4 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 15:13:43 +0100 Subject: [PATCH 08/40] fix --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 35180f40d..fd2ec2db9 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 9d13d0b7f..368303bb4 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index bbf13b7f8..dd6514a80 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,7 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 6b8b07a33..d2f0d69e5 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index e886cffcc..00bf24470 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,7 +8,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 2ceecbaf8..194159f58 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 48f2083bd..332f075a1 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot From cbe424609336c5baab03d86040467bdcd4008ddf Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 15:23:24 +0100 Subject: [PATCH 09/40] trigger CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index fd2ec2db9..0a582bed6 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 368303bb4..1d00ba9ea 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index dd6514a80..523add0c7 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,7 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index d2f0d69e5..129a25be6 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 00bf24470..125430abc 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,7 +8,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index a28b71bd2..2c769d192 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 194159f58..87aeccf99 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 790abfcc7..42cb8f34d 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 332f075a1..bce41c165 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index a893cde72..564708308 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 663c3044c..664d5fa62 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 7e031258c..bf9b89001 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 98607bc02..2547eb9c7 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 877b701a5..5324324fc 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 3bef98a90..ff2f39cfc 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable == true }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From e19e826f5f36efaa311d714f154c5846175e11c1 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 15:25:49 +0100 Subject: [PATCH 10/40] trigger CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 0a582bed6..257bb8ba8 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 1d00ba9ea..a5b72ab91 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 523add0c7..8c9071c37 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -8,7 +8,7 @@ on: jobs: build: if: ${{ !github.event.act }} - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 129a25be6..d23bf26d9 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 125430abc..d1939a786 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -8,7 +8,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 2c769d192..fdfc3e271 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 87aeccf99..52e152474 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 42cb8f34d..b8d372366 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index bce41c165..f42e6e1e4 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 564708308..fe4e5d9b0 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 664d5fa62..619192571 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -12,7 +12,7 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index bf9b89001..13a304ff3 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 2547eb9c7..338411fd4 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 5324324fc..b4e23edc6 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index ff2f39cfc..93c9631d1 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -9,7 +9,7 @@ on: jobs: build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From 00da5c29648c0f16026a46d4755a7d3e43fc1470 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 16:10:46 +0100 Subject: [PATCH 11/40] trigger CI --- .github/workflows/test_package_install_inference_gpu.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index b8d372366..1fb89f2b9 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -12,7 +12,6 @@ permissions: jobs: build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -46,4 +45,8 @@ jobs: - name: 🧪 Testing package installation working-directory: "/" run: | + echo "${{ github.event.pull_request.base.sha }}" + echo "${{ github.event.pull_request.head.sha }}" + echo "${{ github.event_name }}" + echo "${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }}" python -c "import os; import platform; print(f'Python version: {platform.python_version()}'); print(f'CWD: {os.getcwd()}'); from inference import get_model" From b075fd239d431da6eefd441c32cea93cd4cd91a4 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 16:42:10 +0100 Subject: [PATCH 12/40] trigger CI --- .github/workflows/test_package_install_inference_gpu.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 1fb89f2b9..57620084d 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -43,10 +43,9 @@ jobs: - name: 📦 Installing `inference` package... run: pip install ./dist/inference_gpu-*-py3-none-any.whl - name: 🧪 Testing package installation - working-directory: "/" + env: + GITHUB_CONTEXT: ${{ toJSON(github) }} + run: echo "$GITHUB_CONTEXT" working-directory: "/" run: | - echo "${{ github.event.pull_request.base.sha }}" - echo "${{ github.event.pull_request.head.sha }}" - echo "${{ github.event_name }}" - echo "${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }}" + echo "$GITHUB_CONTEXT" python -c "import os; import platform; print(f'Python version: {platform.python_version()}'); print(f'CWD: {os.getcwd()}'); from inference import get_model" From fd01f0347c40894cc983a74650a048d3999503a3 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Fri, 1 Nov 2024 16:46:13 +0100 Subject: [PATCH 13/40] trigger CI --- .github/workflows/test_package_install_inference_gpu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 57620084d..f51cc0af1 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -45,7 +45,7 @@ jobs: - name: 🧪 Testing package installation env: GITHUB_CONTEXT: ${{ toJSON(github) }} - run: echo "$GITHUB_CONTEXT" working-directory: "/" + working-directory: "/" run: | echo "$GITHUB_CONTEXT" python -c "import os; import platform; print(f'Python version: {platform.python_version()}'); print(f'CWD: {os.getcwd()}'); from inference import get_model" From 391e172e4265c9e92de0dc44121d382ef34a8ef3 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 11:31:52 +0100 Subject: [PATCH 14/40] Set mergeable_state in one job, then skip build job based on mergeable_state value --- .../integration_tests_inference_cli_x86.yml | 20 +++++++++++++- .../integration_tests_inference_models.yml | 23 +++++++++++++++- ...integration_tests_inference_server_x86.yml | 19 ++++++++++++- .../integration_tests_workflows_x86.yml | 23 +++++++++++++++- .github/workflows/static_code_analysis.yml | 20 +++++++++++++- .../test_package_install_inference.yml | 20 +++++++++++++- .../test_package_install_inference_cli.yml | 20 +++++++++++++- .../test_package_install_inference_gpu.yml | 27 ++++++++++++++++--- ...kage_install_inference_gpu_with_extras.yml | 20 +++++++++++++- .../test_package_install_inference_sdk.yml | 20 +++++++++++++- ..._package_install_inference_with_extras.yml | 20 +++++++++++++- .../unit_tests_inference_cli_x86.yml | 20 +++++++++++++- .../unit_tests_inference_sdk_x86.yml | 21 ++++++++++++++- .../workflows/unit_tests_inference_x86.yml | 23 +++++++++++++++- .../workflows/unit_tests_workflows_x86.yml | 23 +++++++++++++++- 15 files changed, 302 insertions(+), 17 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 257bb8ba8..a1c4fa9ec 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -2,14 +2,32 @@ name: INTEGRATION TESTS - inference CLI on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index a5b72ab91..cfe1d9624 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -2,14 +2,35 @@ name: INTEGRATION TESTS - inference models on: pull_request: + paths-ignore: + - "**/*.md" + - "inference_sdk/**" + - "inference_cli/**" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 8c9071c37..b63c2b8b0 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -6,9 +6,26 @@ on: workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} if: ${{ !github.event.act }} - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} runs-on: group: group8core timeout-minutes: 35 diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index d23bf26d9..6eddc73f8 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -2,14 +2,35 @@ name: INTEGRATION TESTS - workflows on: pull_request: + paths-ignore: + - "**/*.md" + - "inference_sdk/**" + - "inference_cli/**" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index d1939a786..39c48c4b4 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -2,13 +2,31 @@ name: Static code analysis on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index fdfc3e271..b4b3f298d 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -2,6 +2,7 @@ name: Test package install - inference on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,8 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 52e152474..fdfa92d3c 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -2,6 +2,7 @@ name: Test package install - inference-cli on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,8 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index f51cc0af1..b2a2d29e4 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -2,6 +2,7 @@ name: Test package install - inference-gpu on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,7 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot @@ -20,6 +39,11 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10", "3.11"] steps: + - name: test + env: + - mergeable_state: ${{needs.is_mergeable.outputs.mergeable_state}} + run: | + echo "$mergeable_state" - name: 🛎️ Checkout uses: actions/checkout@v4 - name: 🐍 Set up Python 3.9 to create wheels @@ -43,9 +67,6 @@ jobs: - name: 📦 Installing `inference` package... run: pip install ./dist/inference_gpu-*-py3-none-any.whl - name: 🧪 Testing package installation - env: - GITHUB_CONTEXT: ${{ toJSON(github) }} working-directory: "/" run: | - echo "$GITHUB_CONTEXT" python -c "import os; import platform; print(f'Python version: {platform.python_version()}'); print(f'CWD: {os.getcwd()}'); from inference import get_model" diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index f42e6e1e4..4e33bab69 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -2,6 +2,7 @@ name: Test package install - inference-gpu[extras] on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,8 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index fe4e5d9b0..8d3cf0fb2 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -2,6 +2,7 @@ name: Test package install - inference-sdk on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,8 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 619192571..c4ae727cb 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -2,6 +2,7 @@ name: Test package install - inference[extras] on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -11,8 +12,25 @@ permissions: id-token: write jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 13a304ff3..8fa5a046c 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -2,14 +2,32 @@ name: UNIT TESTS - inference CLI on: pull_request: + paths-ignore: "**/*.md" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 338411fd4..d9d40edb6 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -2,14 +2,33 @@ name: UNIT TESTS - inference SDK on: pull_request: + paths-ignore: + - "**/*.md" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index b4e23edc6..c43a03e3f 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -2,14 +2,35 @@ name: UNIT TESTS - inference on: pull_request: + paths-ignore: + - "**/*.md" + - "inference_sdk/**" + - "inference_cli/**" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 93c9631d1..1e5a5b395 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -2,14 +2,35 @@ name: UNIT TESTS - workflows on: pull_request: + paths-ignore: + - "**/*.md" + - "inference_sdk/**" + - "inference_cli/**" branches: [main] push: branches: [main] workflow_dispatch: jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout + uses: actions/checkout@v4 + - name: Wait for mergeable state + id: mergeable_check + run: | + if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + fi build-dev-test: - if: ${{ github.event_name != 'pull_request' || github.event.pull_request.base.sha == github.event.pull_request.head.sha }} + needs: is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From 1ce7666daaa8f7a85a86863e59f3e9a01e683e95 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 11:57:52 +0100 Subject: [PATCH 15/40] trigger CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index a1c4fa9ec..05709933f 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -22,7 +22,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index cfe1d9624..549b9f409 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index b63c2b8b0..58011cedc 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -19,7 +19,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 6eddc73f8..84be8354d 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 39c48c4b4..dc142f609 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -21,7 +21,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index b4b3f298d..380bb86cd 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index fdfa92d3c..5d0fbf38c 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index b2a2d29e4..10e4889fe 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 4e33bab69..aa7233451 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 8d3cf0fb2..2a64648e2 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index c4ae727cb..3ffa77da7 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 8fa5a046c..f620e6dc2 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -22,7 +22,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index d9d40edb6..6f0ab43a2 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -23,7 +23,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index c43a03e3f..5b2393173 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 1e5a5b395..5519b3d1f 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if [ ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }} ]; then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: From ff3279ff82cf9b11ab9efe99d272c1882923cb2c Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:02:22 +0100 Subject: [PATCH 16/40] trigger CI --- .github/workflows/integration_tests_workflows_x86.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 84be8354d..42158ddcf 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -25,6 +25,8 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | + echo ${{ github.event.pull_request.base.sha }} + echo ${{ github.event.pull_request.head.sha }} if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi From 2570fe65c52fc0a970e249ad79ef904434af81c3 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:07:12 +0100 Subject: [PATCH 17/40] trigger CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_inference_server_x86.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 4 +--- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 15 files changed, 15 insertions(+), 17 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 05709933f..f2f0cbe95 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -22,7 +22,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 549b9f409..df265a578 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 58011cedc..5d0e05bc9 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -19,7 +19,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 42158ddcf..804e4f93a 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -25,9 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - echo ${{ github.event.pull_request.base.sha }} - echo ${{ github.event.pull_request.head.sha }} - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index dc142f609..1a627a626 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -21,7 +21,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 380bb86cd..a432478a3 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 5d0fbf38c..0f29fc57f 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 10e4889fe..4874c8b33 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index aa7233451..7e3b42be7 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 2a64648e2..7b2572bc3 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 3ffa77da7..344501e18 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build: diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index f620e6dc2..ca2dcd45a 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -22,7 +22,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 6f0ab43a2..4a602575d 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -23,7 +23,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 5b2393173..a37e9687e 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 5519b3d1f..73a67f20a 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -25,7 +25,7 @@ jobs: - name: Wait for mergeable state id: mergeable_check run: | - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" fi build-dev-test: From 5a67e64a0444b8d25f29503e922012cea50b91cf Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:13:52 +0100 Subject: [PATCH 18/40] Remove path-ignore --- .github/workflows/integration_tests_inference_cli_x86.yml | 4 ++-- .github/workflows/integration_tests_inference_models.yml | 7 ++----- .github/workflows/integration_tests_workflows_x86.yml | 7 ++----- .github/workflows/static_code_analysis.yml | 4 ++-- .github/workflows/test_package_install_inference.yml | 4 ++-- .github/workflows/test_package_install_inference_cli.yml | 4 ++-- .github/workflows/test_package_install_inference_gpu.yml | 4 ++-- .../test_package_install_inference_gpu_with_extras.yml | 4 ++-- .github/workflows/test_package_install_inference_sdk.yml | 4 ++-- .../test_package_install_inference_with_extras.yml | 4 ++-- .github/workflows/unit_tests_inference_cli_x86.yml | 4 ++-- .github/workflows/unit_tests_inference_sdk_x86.yml | 5 ++--- .github/workflows/unit_tests_inference_x86.yml | 7 ++----- .github/workflows/unit_tests_workflows_x86.yml | 7 ++----- 14 files changed, 28 insertions(+), 41 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index f2f0cbe95..04d62b7c0 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -2,7 +2,6 @@ name: INTEGRATION TESTS - inference CLI on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -23,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index df265a578..4227971e1 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -2,10 +2,6 @@ name: INTEGRATION TESTS - inference models on: pull_request: - paths-ignore: - - "**/*.md" - - "inference_sdk/**" - - "inference_cli/**" branches: [main] push: branches: [main] @@ -26,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 804e4f93a..2c5c10cd8 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -2,10 +2,6 @@ name: INTEGRATION TESTS - workflows on: pull_request: - paths-ignore: - - "**/*.md" - - "inference_sdk/**" - - "inference_cli/**" branches: [main] push: branches: [main] @@ -26,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 1a627a626..9a5f0d165 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -2,7 +2,6 @@ name: Static code analysis on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -22,7 +21,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index a432478a3..98c302f84 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -2,7 +2,6 @@ name: Test package install - inference on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 0f29fc57f..e57620a91 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -2,7 +2,6 @@ name: Test package install - inference-cli on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 4874c8b33..fe4adc3eb 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -2,7 +2,6 @@ name: Test package install - inference-gpu on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 7e3b42be7..8fdb8163c 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -2,7 +2,6 @@ name: Test package install - inference-gpu[extras] on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 7b2572bc3..141a7543b 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -2,7 +2,6 @@ name: Test package install - inference-sdk on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 344501e18..8c57ba04f 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -2,7 +2,6 @@ name: Test package install - inference[extras] on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -26,7 +25,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index ca2dcd45a..816be427f 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -2,7 +2,6 @@ name: UNIT TESTS - inference CLI on: pull_request: - paths-ignore: "**/*.md" branches: [main] push: branches: [main] @@ -23,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 4a602575d..9fdde3b10 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -2,8 +2,6 @@ name: UNIT TESTS - inference SDK on: pull_request: - paths-ignore: - - "**/*.md" branches: [main] push: branches: [main] @@ -24,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index a37e9687e..e601f1124 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -2,10 +2,6 @@ name: UNIT TESTS - inference on: pull_request: - paths-ignore: - - "**/*.md" - - "inference_sdk/**" - - "inference_cli/**" branches: [main] push: branches: [main] @@ -26,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 73a67f20a..26649378d 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -2,10 +2,6 @@ name: UNIT TESTS - workflows on: pull_request: - paths-ignore: - - "**/*.md" - - "inference_sdk/**" - - "inference_cli/**" branches: [main] push: branches: [main] @@ -26,7 +22,8 @@ jobs: id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable From 8abe97711918bd76dc2f10ff7b48698e600089fd Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:15:05 +0100 Subject: [PATCH 19/40] Remove check from INTEGRATION TESTS - Inference Server CPU x86 --- ...integration_tests_inference_server_x86.yml | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 5d0e05bc9..43866a907 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -5,26 +5,7 @@ on: branches: [ main ] workflow_dispatch: -jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: 🛎️ Checkout - uses: actions/checkout@v4 - - name: Wait for mergeable state - id: mergeable_check - run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT" - fi build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} if: ${{ !github.event.act }} runs-on: group: group8core From 5f320847afe8a1ca5ad6f4fe3ac095f00b7eac99 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:32:14 +0100 Subject: [PATCH 20/40] Checkout main and branch with depth 1; test for not clean defaulting to action always executed in case is_mergeable fails with error --- .../integration_tests_inference_cli_x86.yml | 16 ++++++++++++---- .../integration_tests_inference_models.yml | 2 +- .../integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .../workflows/test_package_install_inference.yml | 2 +- .../test_package_install_inference_cli.yml | 2 +- .../test_package_install_inference_gpu.yml | 2 +- ...package_install_inference_gpu_with_extras.yml | 2 +- .../test_package_install_inference_sdk.yml | 2 +- ...est_package_install_inference_with_extras.yml | 2 +- .../workflows/unit_tests_inference_cli_x86.yml | 2 +- .../workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 14 files changed, 25 insertions(+), 17 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 04d62b7c0..bcea5629b 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -16,18 +16,26 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout main + uses: actions/checkout@v4 + fetch-depth: 1 + ref: ${{ github.event.pull_request.base.sha }} + - name: 🛎️ Checkout branch uses: actions/checkout@v4 - - name: Wait for mergeable state + fetch-depth: 1 + - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 4227971e1..63f16a494 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 2c5c10cd8..b2ff7a98b 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 9a5f0d165..6f4a0be85 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -17,7 +17,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 98c302f84..e8f498a74 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index e57620a91..cfb5fe2ed 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index fe4adc3eb..882e62429 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 8fdb8163c..bd37da89a 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 141a7543b..b207df633 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 8c57ba04f..ed1e6afdb 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -21,7 +21,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 816be427f..674d91924 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 9fdde3b10..7ac44cba8 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index e601f1124..dd77bf367 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 26649378d..64e6461ee 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -18,7 +18,7 @@ jobs: steps: - name: 🛎️ Checkout uses: actions/checkout@v4 - - name: Wait for mergeable state + - name: Check and store mergable state id: mergeable_check run: | if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then From 3af37596268db5083733192458a121f10c0ccfe2 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:36:59 +0100 Subject: [PATCH 21/40] trigger CI --- .../workflows/integration_tests_inference_cli_x86.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index bcea5629b..dc2ee674a 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -17,12 +17,14 @@ jobs: timeout-minutes: 15 steps: - name: 🛎️ Checkout main - uses: actions/checkout@v4 - fetch-depth: 1 - ref: ${{ github.event.pull_request.base.sha }} + uses: + with: + fetch-depth: 1 + ref: ${{ github.event.pull_request.base.sha }} - name: 🛎️ Checkout branch uses: actions/checkout@v4 - fetch-depth: 1 + with: + fetch-depth: 1 - name: Check and store mergable state id: mergeable_check run: | From 889d944984ed53643e39067a839d2456e5f60433 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:39:53 +0100 Subject: [PATCH 22/40] trigger CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index dc2ee674a..07fe754da 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -17,7 +17,7 @@ jobs: timeout-minutes: 15 steps: - name: 🛎️ Checkout main - uses: + uses: actions/checkout@v4 with: fetch-depth: 1 ref: ${{ github.event.pull_request.base.sha }} From 14758a891bbd61db208c587dd4d5249db8b5265a Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:46:56 +0100 Subject: [PATCH 23/40] CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 07fe754da..6d6d77e46 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -28,6 +28,7 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | + echo "Check if ${{ github.event.pull_request.base.sha }} is ancestor of ${{ github.event.pull_request.head.sha }}"; if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; From 425b73f50e0f4cc25bb6bda1dd125923f8dc31b6 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:50:45 +0100 Subject: [PATCH 24/40] CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 6d6d77e46..158b7a541 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -23,8 +23,6 @@ jobs: ref: ${{ github.event.pull_request.base.sha }} - name: 🛎️ Checkout branch uses: actions/checkout@v4 - with: - fetch-depth: 1 - name: Check and store mergable state id: mergeable_check run: | From 78f638ddf69b4b1afdc57fe3e82cdc13ce8cbb77 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:54:04 +0100 Subject: [PATCH 25/40] Test against branch HEAD --- .github/workflows/integration_tests_inference_cli_x86.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 158b7a541..b702fbedd 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.base.sha }} is ancestor of ${{ github.event.pull_request.head.sha }}"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if branch HEAD is ancestor of ${{ github.event.pull_request.head.sha }}"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} HEAD); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else From 5f8d9ee4f574f05e34740db3d08beba9374ce475 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 13:02:14 +0100 Subject: [PATCH 26/40] check main sha --- .github/workflows/integration_tests_inference_cli_x86.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index b702fbedd..2a1c2f443 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -26,6 +26,7 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | + echo "${{ toJSON(github) }}" echo "Check if branch HEAD is ancestor of ${{ github.event.pull_request.head.sha }}"; if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} HEAD); then echo "Branch is mergeable"; From 413f89c92b4a4772c84f55fd510602f6303f01fe Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 13:07:09 +0100 Subject: [PATCH 27/40] CI --- .github/workflows/integration_tests_inference_cli_x86.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 2a1c2f443..1e109d94f 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -26,9 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "${{ toJSON(github) }}" - echo "Check if branch HEAD is ancestor of ${{ github.event.pull_request.head.sha }}"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} HEAD); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else From b74b846744f0445ac4ea5425ce2fdbbcb21e643e Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 13:24:00 +0100 Subject: [PATCH 28/40] Instead of running 'git merge-base --is-ancestor' run 'git merge --no-commit --no-ff' --- .../integration_tests_inference_cli_x86.yml | 12 +++++++----- .../integration_tests_inference_server_x86.yml | 1 + 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 1e109d94f..893fdab94 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -16,24 +16,26 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout main + - name: 🛎️ Checkout main HEAD uses: actions/checkout@v4 with: - fetch-depth: 1 ref: ${{ github.event.pull_request.base.sha }} - - name: 🛎️ Checkout branch + - name: 🛎️ Checkout branch HEAD uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) can be merged with ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge --no-commit --no-ff ${{ github.event.pull_request.base.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else echo "Branch needs to be updated"; echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi + git reset --merge build-dev-test: needs: is_mergeable if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state != 'not_clean' }} diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 43866a907..2e79bc4fa 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -5,6 +5,7 @@ on: branches: [ main ] workflow_dispatch: +jobs: build: if: ${{ !github.event.act }} runs-on: From 61718042e638c76cf82ce01ae71b5ac6ca91b901 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 13:29:05 +0100 Subject: [PATCH 29/40] Fetch all history of branch --- .../integration_tests_inference_cli_x86.yml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 893fdab94..584aa03e8 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -16,26 +16,22 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout main HEAD - uses: actions/checkout@v4 - with: - ref: ${{ github.event.pull_request.base.sha }} - - name: 🛎️ Checkout branch HEAD + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: + fetch-depth: 0 ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) can be merged with ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge --no-commit --no-ff ${{ github.event.pull_request.base.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else echo "Branch needs to be updated"; echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi - git reset --merge build-dev-test: needs: is_mergeable if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state != 'not_clean' }} From 11e481f8502d3294d67c251e145cc2828799e5f0 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 13:42:08 +0100 Subject: [PATCH 30/40] roll out across all relevant workflows --- .../workflows/integration_tests_inference_models.yml | 11 +++++++++-- .github/workflows/integration_tests_workflows_x86.yml | 11 +++++++++-- .github/workflows/static_code_analysis.yml | 11 +++++++++-- .github/workflows/test_package_install_inference.yml | 11 +++++++++-- .../workflows/test_package_install_inference_cli.yml | 11 +++++++++-- .../workflows/test_package_install_inference_gpu.yml | 11 +++++++++-- ...test_package_install_inference_gpu_with_extras.yml | 11 +++++++++-- .../workflows/test_package_install_inference_sdk.yml | 11 +++++++++-- .../test_package_install_inference_with_extras.yml | 11 +++++++++-- .github/workflows/unit_tests_inference_cli_x86.yml | 11 +++++++++-- .github/workflows/unit_tests_inference_sdk_x86.yml | 11 +++++++++-- .github/workflows/unit_tests_inference_x86.yml | 11 +++++++++-- .github/workflows/unit_tests_workflows_x86.yml | 11 +++++++++-- 13 files changed, 117 insertions(+), 26 deletions(-) diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 63f16a494..7d75bed5a 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index b2ff7a98b..c6329f06c 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 6f4a0be85..ea5dbb790 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -15,14 +15,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index e8f498a74..1f5aad456 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index cfb5fe2ed..18d3bdc44 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 882e62429..7e509a9cf 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index bd37da89a..072168dca 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index b207df633..98fbc4f65 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index ed1e6afdb..60e785b61 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -19,14 +19,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 674d91924..ff135ad5a 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 7ac44cba8..aa5844909 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index dd77bf367..afe0a59b6 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 64e6461ee..35d42828a 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -16,14 +16,21 @@ jobs: group: public-depot timeout-minutes: 15 steps: - - name: 🛎️ Checkout + - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check run: | - if $(git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }}); then + echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; + if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; fi build-dev-test: needs: is_mergeable From 8506506eda2ec833ea058f89cc80a3f42375672c Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 16:13:25 +0100 Subject: [PATCH 31/40] Reduce number of commits to be fetched --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 2 +- 14 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 584aa03e8..bc3c41d35 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 7d75bed5a..a2435796e 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index c6329f06c..ce4b905c8 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index ea5dbb790..2b88c938a 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -18,7 +18,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 1f5aad456..5fb578be9 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 18d3bdc44..0f875aed9 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 7e509a9cf..c099e4e6b 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 072168dca..214338534 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 98fbc4f65..d1f87b0e2 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 60e785b61..8cf8a07ed 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -22,7 +22,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index ff135ad5a..6ff442c9c 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index aa5844909..05f214f96 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index afe0a59b6..0374a3e1f 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 35d42828a..2248fab4e 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -19,7 +19,7 @@ jobs: - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: 0 + fetch-depth: ${{ github.event.pull_request.commits + 1 }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check From 334c8409ef109a50def1a99c74907e646eae32e3 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 16:19:11 +0100 Subject: [PATCH 32/40] Store fetch depth in env --- .github/workflows/integration_tests_inference_cli_x86.yml | 4 +++- .github/workflows/integration_tests_inference_models.yml | 4 +++- .github/workflows/integration_tests_workflows_x86.yml | 4 +++- .github/workflows/static_code_analysis.yml | 4 +++- .github/workflows/test_package_install_inference.yml | 4 +++- .github/workflows/test_package_install_inference_cli.yml | 4 +++- .github/workflows/test_package_install_inference_gpu.yml | 4 +++- .../test_package_install_inference_gpu_with_extras.yml | 4 +++- .github/workflows/test_package_install_inference_sdk.yml | 4 +++- .../workflows/test_package_install_inference_with_extras.yml | 4 +++- .github/workflows/unit_tests_inference_cli_x86.yml | 4 +++- .github/workflows/unit_tests_inference_sdk_x86.yml | 4 +++- .github/workflows/unit_tests_inference_x86.yml | 4 +++- .github/workflows/unit_tests_workflows_x86.yml | 4 +++- 14 files changed, 42 insertions(+), 14 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index bc3c41d35..f798a93da 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index a2435796e..31feb97db 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index ce4b905c8..479c37e5e 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 2b88c938a..1c2dca104 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -15,10 +15,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 5fb578be9..184e27dcc 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index 0f875aed9..bad762d7a 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index c099e4e6b..3f897004f 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 214338534..5637573ab 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index d1f87b0e2..33001a345 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 8cf8a07ed..104bf946a 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -19,10 +19,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 6ff442c9c..060b94152 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 05f214f96..adcde8412 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 0374a3e1f..647631e32 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 2248fab4e..84dc42536 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -16,10 +16,12 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history uses: actions/checkout@v4 with: - fetch-depth: ${{ github.event.pull_request.commits + 1 }} + fetch-depth: ${{ env.FETCH_DEPTH }} ref: ${{ github.event.pull_request.head.sha }} - name: Check and store mergable state id: mergeable_check From 2ba396d413403c79d64a427de7c3cdf052e2e791 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 16:26:07 +0100 Subject: [PATCH 33/40] fetch main; test for acnestry against main --- .../workflows/integration_tests_inference_cli_x86.yml | 4 ++-- .github/workflows/integration_tests_inference_models.yml | 4 ++-- .github/workflows/integration_tests_workflows_x86.yml | 4 ++-- .github/workflows/static_code_analysis.yml | 4 ++-- .github/workflows/test_package_install_inference.yml | 4 ++-- .github/workflows/test_package_install_inference_cli.yml | 4 ++-- .github/workflows/test_package_install_inference_gpu.yml | 4 ++-- .../test_package_install_inference_gpu_with_extras.yml | 4 ++-- .github/workflows/test_package_install_inference_sdk.yml | 4 ++-- .../test_package_install_inference_with_extras.yml | 4 ++-- .github/workflows/unit_tests_inference_cli_x86.yml | 4 ++-- .github/workflows/unit_tests_inference_sdk_x86.yml | 4 ++-- .github/workflows/unit_tests_inference_x86.yml | 4 ++-- .github/workflows/unit_tests_workflows_x86.yml | 9 +++++++-- 14 files changed, 33 insertions(+), 28 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index f798a93da..7bce7d209 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 31feb97db..1debb9be6 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 479c37e5e..8b1eb8106 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 1c2dca104..2e35412ca 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -25,8 +25,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 184e27dcc..88f347ca2 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index bad762d7a..bef590796 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 3f897004f..6558538a7 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 5637573ab..157e88b9c 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 33001a345..1bb53991f 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 104bf946a..97603d3b2 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -29,8 +29,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 060b94152..ea9e06ae9 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index adcde8412..22d02e4af 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 647631e32..06039b5a4 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -26,8 +26,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 84dc42536..a713982d1 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -16,6 +16,11 @@ jobs: group: public-depot timeout-minutes: 15 steps: + - name: 🛎️ Checkout main + uses: actions/checkout@v4 + with: + fetch-depth: ${{ env.FETCH_DEPTH }} + ref: main - name: Calculate depth run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history @@ -26,8 +31,8 @@ jobs: - name: Check and store mergable state id: mergeable_check run: | - echo "Check if ${{ github.event.pull_request.head.sha }} (branch HEAD) is ancestor of ${{ github.event.pull_request.base.sha }} (main HEAD)"; - if $(git merge-base --is-ancestor ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else From 3580f9a64cb415064a98be14db40ab500d058f5b Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 16:31:55 +0100 Subject: [PATCH 34/40] store main sha in github context --- .github/workflows/unit_tests_workflows_x86.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index a713982d1..cc5bb0ca1 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -21,6 +21,8 @@ jobs: with: fetch-depth: ${{ env.FETCH_DEPTH }} ref: main + - name : Store main sha in context + run: echo "main_sha=$(git rev-parse main)" >> "${GITHUB_ENV}" - name: Calculate depth run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - name: 🛎️ Checkout branch with all history @@ -32,7 +34,7 @@ jobs: id: mergeable_check run: | echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then + if $(git merge-base --is-ancestor ${{ env.main_sha }} ${{ github.event.pull_request.head.sha }}); then echo "Branch is mergeable"; echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; else From 444573ff70d6f6473b7ca22eab58220cd0a92d02 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 17:24:59 +0100 Subject: [PATCH 35/40] move shared code into callable workflow --- .github/workflows/is_mergeable.yml | 39 ++++++++++++++++++ .../workflows/unit_tests_workflows_x86.yml | 40 +++---------------- 2 files changed, 44 insertions(+), 35 deletions(-) create mode 100644 .github/workflows/is_mergeable.yml diff --git a/.github/workflows/is_mergeable.yml b/.github/workflows/is_mergeable.yml new file mode 100644 index 000000000..1a3ec622a --- /dev/null +++ b/.github/workflows/is_mergeable.yml @@ -0,0 +1,39 @@ +name: Check if PR is mergeable + +on: + workflow_call: + +jobs: + is_mergeable: + outputs: + mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} + runs-on: + labels: depot-ubuntu-22.04-8 + group: public-depot + timeout-minutes: 15 + steps: + - name: 🛎️ Checkout main + uses: actions/checkout@v4 + with: + fetch-depth: ${{ env.FETCH_DEPTH }} + ref: main + - name : Store main sha in context + run: echo "main_sha=$(git rev-parse main)" >> "${GITHUB_ENV}" + - name: Calculate depth + run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" + - name: 🛎️ Checkout branch with all history + uses: actions/checkout@v4 + with: + fetch-depth: ${{ env.FETCH_DEPTH }} + ref: ${{ github.event.pull_request.head.sha }} + - name: Check and store mergable state + id: mergeable_check + run: | + echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; + if $(git merge-base --is-ancestor ${{ env.main_sha }} ${{ github.event.pull_request.head.sha }}); then + echo "Branch is mergeable"; + echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; + else + echo "Branch needs to be updated"; + echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; + fi diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index cc5bb0ca1..44ab22197 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -8,42 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: 🛎️ Checkout main - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: main - - name : Store main sha in context - run: echo "main_sha=$(git rev-parse main)" >> "${GITHUB_ENV}" - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor ${{ env.main_sha }} ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From 85a5294ee42e33b164794ed6ad6dda0e98c7241f Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 17:37:30 +0100 Subject: [PATCH 36/40] Roll out callable workflow across pull request workflows --- .../integration_tests_inference_cli_x86.yml | 33 +++---------------- .../integration_tests_inference_models.yml | 33 +++---------------- .../integration_tests_workflows_x86.yml | 33 +++---------------- .github/workflows/static_code_analysis.yml | 33 +++---------------- .../test_package_install_inference.yml | 33 +++---------------- .../test_package_install_inference_cli.yml | 33 +++---------------- .../test_package_install_inference_gpu.yml | 33 +++---------------- ...kage_install_inference_gpu_with_extras.yml | 33 +++---------------- .../test_package_install_inference_sdk.yml | 33 +++---------------- ..._package_install_inference_with_extras.yml | 33 +++---------------- .../unit_tests_inference_cli_x86.yml | 33 +++---------------- .../unit_tests_inference_sdk_x86.yml | 33 +++---------------- .../workflows/unit_tests_inference_x86.yml | 33 +++---------------- 13 files changed, 65 insertions(+), 364 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 7bce7d209..06d8ff249 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state != 'not_clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 1debb9be6..1a1f61f2e 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index 8b1eb8106..c33004d35 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 2e35412ca..3befec0b6 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -7,35 +7,12 @@ on: branches: [main] jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 88f347ca2..62f883488 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index bef590796..aa06d8d3e 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 6558538a7..7d952b78d 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 157e88b9c..05a3c00b0 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 1bb53991f..8202e71c6 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 97603d3b2..8a2d2450b 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -11,35 +11,12 @@ permissions: id-token: write jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index ea9e06ae9..21d50e2d0 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index 22d02e4af..edecf66fd 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index 06039b5a4..a5f113b4d 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -8,35 +8,12 @@ on: workflow_dispatch: jobs: - is_mergeable: - outputs: - mergeable_state: ${{ steps.mergeable_check.outputs.mergeable_state }} - runs-on: - labels: depot-ubuntu-22.04-8 - group: public-depot - timeout-minutes: 15 - steps: - - name: Calculate depth - run: echo "FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> "${GITHUB_ENV}" - - name: 🛎️ Checkout branch with all history - uses: actions/checkout@v4 - with: - fetch-depth: ${{ env.FETCH_DEPTH }} - ref: ${{ github.event.pull_request.head.sha }} - - name: Check and store mergable state - id: mergeable_check - run: | - echo "Check if main is ancestor of ${{ github.event.pull_request.head.sha }} (branch HEAD)"; - if $(git merge-base --is-ancestor main ${{ github.event.pull_request.head.sha }}); then - echo "Branch is mergeable"; - echo "mergeable_state=clean" >> "$GITHUB_OUTPUT"; - else - echo "Branch needs to be updated"; - echo "mergeable_state=not_clean" >> "$GITHUB_OUTPUT"; - fi + call_is_mergeable: + uses: ./.github/workflows/is_mergeable.yml + secrets: inherit build-dev-test: - needs: is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.is_mergeable.outputs.mergeable_state == 'clean' }} + needs: call_is_mergeable + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot From 09d973458dd0c8cffc63036c3cd920551ba20756 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 17:46:28 +0100 Subject: [PATCH 37/40] Test inter-workflow state share --- .github/workflows/unit_tests_workflows_x86.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index 44ab22197..a89b89afc 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot @@ -40,6 +40,7 @@ jobs: check-latest: true - name: 📦 Install dependencies run: | + echo "######################### ${{ needs.call_is_mergeable.outputs.mergeable_state }}" python -m pip install --upgrade pip pip install --upgrade setuptools pip install -r requirements/_requirements.txt -r requirements/requirements.cpu.txt -r requirements/requirements.sdk.http.txt -r requirements/requirements.test.unit.txt -r requirements/requirements.http.txt From d0f0704b0a4bd7723246fdbd035c04a5b2eafea7 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Mon, 4 Nov 2024 17:52:33 +0100 Subject: [PATCH 38/40] Expose callable workflow output --- .github/workflows/integration_tests_inference_cli_x86.yml | 2 +- .github/workflows/integration_tests_inference_models.yml | 2 +- .github/workflows/integration_tests_workflows_x86.yml | 2 +- .github/workflows/is_mergeable.yml | 4 ++++ .github/workflows/static_code_analysis.yml | 2 +- .github/workflows/test_package_install_inference.yml | 2 +- .github/workflows/test_package_install_inference_cli.yml | 2 +- .github/workflows/test_package_install_inference_gpu.yml | 2 +- .../test_package_install_inference_gpu_with_extras.yml | 2 +- .github/workflows/test_package_install_inference_sdk.yml | 2 +- .../workflows/test_package_install_inference_with_extras.yml | 2 +- .github/workflows/unit_tests_inference_cli_x86.yml | 2 +- .github/workflows/unit_tests_inference_sdk_x86.yml | 2 +- .github/workflows/unit_tests_inference_x86.yml | 2 +- .github/workflows/unit_tests_workflows_x86.yml | 1 - 15 files changed, 17 insertions(+), 14 deletions(-) diff --git a/.github/workflows/integration_tests_inference_cli_x86.yml b/.github/workflows/integration_tests_inference_cli_x86.yml index 06d8ff249..b2527851c 100644 --- a/.github/workflows/integration_tests_inference_cli_x86.yml +++ b/.github/workflows/integration_tests_inference_cli_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/integration_tests_inference_models.yml b/.github/workflows/integration_tests_inference_models.yml index 1a1f61f2e..ea951c0ce 100644 --- a/.github/workflows/integration_tests_inference_models.yml +++ b/.github/workflows/integration_tests_inference_models.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/integration_tests_workflows_x86.yml b/.github/workflows/integration_tests_workflows_x86.yml index c33004d35..47755481d 100644 --- a/.github/workflows/integration_tests_workflows_x86.yml +++ b/.github/workflows/integration_tests_workflows_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-16 group: public-depot diff --git a/.github/workflows/is_mergeable.yml b/.github/workflows/is_mergeable.yml index 1a3ec622a..613851a7d 100644 --- a/.github/workflows/is_mergeable.yml +++ b/.github/workflows/is_mergeable.yml @@ -2,6 +2,10 @@ name: Check if PR is mergeable on: workflow_call: + outputs: + mergeable_state: + description: "Set to 'clean' if branch is mergeable, otherwise set to 'not_clean'" + value: ${{ jobs.mergeable_check.outputs.mergeable_state }} jobs: is_mergeable: diff --git a/.github/workflows/static_code_analysis.yml b/.github/workflows/static_code_analysis.yml index 3befec0b6..e1dcb994f 100644 --- a/.github/workflows/static_code_analysis.yml +++ b/.github/workflows/static_code_analysis.yml @@ -12,7 +12,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-small group: public-depot diff --git a/.github/workflows/test_package_install_inference.yml b/.github/workflows/test_package_install_inference.yml index 62f883488..845741734 100644 --- a/.github/workflows/test_package_install_inference.yml +++ b/.github/workflows/test_package_install_inference.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_cli.yml b/.github/workflows/test_package_install_inference_cli.yml index aa06d8d3e..60fb93c49 100644 --- a/.github/workflows/test_package_install_inference_cli.yml +++ b/.github/workflows/test_package_install_inference_cli.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu.yml b/.github/workflows/test_package_install_inference_gpu.yml index 7d952b78d..221e61f3a 100644 --- a/.github/workflows/test_package_install_inference_gpu.yml +++ b/.github/workflows/test_package_install_inference_gpu.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_gpu_with_extras.yml b/.github/workflows/test_package_install_inference_gpu_with_extras.yml index 05a3c00b0..77cbe76d3 100644 --- a/.github/workflows/test_package_install_inference_gpu_with_extras.yml +++ b/.github/workflows/test_package_install_inference_gpu_with_extras.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_sdk.yml b/.github/workflows/test_package_install_inference_sdk.yml index 8202e71c6..1e82242f5 100644 --- a/.github/workflows/test_package_install_inference_sdk.yml +++ b/.github/workflows/test_package_install_inference_sdk.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/test_package_install_inference_with_extras.yml b/.github/workflows/test_package_install_inference_with_extras.yml index 8a2d2450b..b32ab00db 100644 --- a/.github/workflows/test_package_install_inference_with_extras.yml +++ b/.github/workflows/test_package_install_inference_with_extras.yml @@ -16,7 +16,7 @@ jobs: secrets: inherit build: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-8 group: public-depot diff --git a/.github/workflows/unit_tests_inference_cli_x86.yml b/.github/workflows/unit_tests_inference_cli_x86.yml index 21d50e2d0..758850b7b 100644 --- a/.github/workflows/unit_tests_inference_cli_x86.yml +++ b/.github/workflows/unit_tests_inference_cli_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_sdk_x86.yml b/.github/workflows/unit_tests_inference_sdk_x86.yml index edecf66fd..a8561cdf0 100644 --- a/.github/workflows/unit_tests_inference_sdk_x86.yml +++ b/.github/workflows/unit_tests_inference_sdk_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_inference_x86.yml b/.github/workflows/unit_tests_inference_x86.yml index a5f113b4d..62e9a5664 100644 --- a/.github/workflows/unit_tests_inference_x86.yml +++ b/.github/workflows/unit_tests_inference_x86.yml @@ -13,7 +13,7 @@ jobs: secrets: inherit build-dev-test: needs: call_is_mergeable - if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state == 'clean' }} + if: ${{ github.event_name != 'pull_request' || needs.call_is_mergeable.outputs.mergeable_state != 'not_clean' }} runs-on: labels: depot-ubuntu-22.04-4 group: public-depot diff --git a/.github/workflows/unit_tests_workflows_x86.yml b/.github/workflows/unit_tests_workflows_x86.yml index a89b89afc..969b488e0 100644 --- a/.github/workflows/unit_tests_workflows_x86.yml +++ b/.github/workflows/unit_tests_workflows_x86.yml @@ -40,7 +40,6 @@ jobs: check-latest: true - name: 📦 Install dependencies run: | - echo "######################### ${{ needs.call_is_mergeable.outputs.mergeable_state }}" python -m pip install --upgrade pip pip install --upgrade setuptools pip install -r requirements/_requirements.txt -r requirements/requirements.cpu.txt -r requirements/requirements.sdk.http.txt -r requirements/requirements.test.unit.txt -r requirements/requirements.http.txt From 38dc0d0d133a1d919e77ea15937f9f42b8b65787 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Tue, 5 Nov 2024 16:33:07 +0100 Subject: [PATCH 39/40] Revert file which should not be affected --- .github/workflows/integration_tests_inference_server_x86.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/integration_tests_inference_server_x86.yml b/.github/workflows/integration_tests_inference_server_x86.yml index 2e79bc4fa..252b0939e 100644 --- a/.github/workflows/integration_tests_inference_server_x86.yml +++ b/.github/workflows/integration_tests_inference_server_x86.yml @@ -26,6 +26,7 @@ jobs: uses: actions/checkout@v3 with: ref: ${{ github.head_ref }} + - name: 🦾 Install dependencies run: | python -m pip install --upgrade pip From d39135fdb5c7e932ddbbf28bcadc9cbbae084c84 Mon Sep 17 00:00:00 2001 From: Grzegorz Klimaszewski <166530809+grzegorz-roboflow@users.noreply.github.com> Date: Tue, 5 Nov 2024 16:41:28 +0100 Subject: [PATCH 40/40] Correction to is_mergeable workflow --- .github/workflows/is_mergeable.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/is_mergeable.yml b/.github/workflows/is_mergeable.yml index 613851a7d..3e6644785 100644 --- a/.github/workflows/is_mergeable.yml +++ b/.github/workflows/is_mergeable.yml @@ -5,7 +5,7 @@ on: outputs: mergeable_state: description: "Set to 'clean' if branch is mergeable, otherwise set to 'not_clean'" - value: ${{ jobs.mergeable_check.outputs.mergeable_state }} + value: ${{ jobs.is_mergeable.outputs.mergeable_state }} jobs: is_mergeable: