From 23dd832a651bb354f9a7ba4f0f718e5a7815bbdb Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Wed, 8 Apr 2026 11:23:39 -0500 Subject: [PATCH 1/7] don't waste GH resources on draft PR --- .github/workflows/combined_format_lint_test_mypy.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index 97696f8767..992a1f81af 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -5,12 +5,19 @@ on: branches: [ dev ] pull_request: branches: [ dev ] + types: [opened, synchronize, reopened, ready_for_review] workflow_dispatch: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} jobs: + fail_if_pull_request_is_draft: + if: github.event.pull_request.draft == true + runs-on: ubuntu-latest + steps: + - name: Fails in order to indicate that PR needs to be marked as ready to review and other checks passed. + run: exit 1 # don't run other jobs format_code: runs-on: ubuntu-latest outputs: From 402117e5dc8af4e28fceb778a72267d257b375ff Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Wed, 8 Apr 2026 11:53:41 -0500 Subject: [PATCH 2/7] add job dependence on draft job --- .github/workflows/combined_format_lint_test_mypy.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index 992a1f81af..d1bbaf928a 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -19,6 +19,7 @@ jobs: - name: Fails in order to indicate that PR needs to be marked as ready to review and other checks passed. run: exit 1 # don't run other jobs format_code: + needs: fail_if_pull_request_is_draft runs-on: ubuntu-latest outputs: changelog_updated: ${{ steps.record_if_changelog_updated.outputs.is_changelog_updated }} From 5572d39f3fc3deba9c69b61110daac1309a2a560 Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Wed, 8 Apr 2026 12:01:03 -0500 Subject: [PATCH 3/7] switched 'needs' for 'if' --- .github/workflows/combined_format_lint_test_mypy.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index d1bbaf928a..cada2eed5c 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -19,7 +19,7 @@ jobs: - name: Fails in order to indicate that PR needs to be marked as ready to review and other checks passed. run: exit 1 # don't run other jobs format_code: - needs: fail_if_pull_request_is_draft + if: github.event.pull_request.draft == false runs-on: ubuntu-latest outputs: changelog_updated: ${{ steps.record_if_changelog_updated.outputs.is_changelog_updated }} @@ -176,6 +176,7 @@ jobs: lint_test_type_check: name: Lint, Test, Coverage, and Type Checking + if: github.event.pull_request.draft == false needs: format_code runs-on: ubuntu-latest steps: From a3a98ebeb5295147142686634da849ec7c45ea8c Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Wed, 8 Apr 2026 12:10:42 -0500 Subject: [PATCH 4/7] add converted_to_draft trigger so that this action will run when the PR is switched to draft (to allow the first job to fail, rather than skip) --- .github/workflows/combined_format_lint_test_mypy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index cada2eed5c..c902dcba54 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -5,7 +5,7 @@ on: branches: [ dev ] pull_request: branches: [ dev ] - types: [opened, synchronize, reopened, ready_for_review] + types: [opened, synchronize, reopened, ready_for_review, converted_to_draft] workflow_dispatch: env: From 3a40987bcc0badde254d6218e5fd9ad9649d4b40 Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Wed, 8 Apr 2026 12:31:09 -0500 Subject: [PATCH 5/7] added changes to changelog --- changelog.md | 1 + 1 file changed, 1 insertion(+) diff --git a/changelog.md b/changelog.md index 10ab98d822..a7a462a30d 100644 --- a/changelog.md +++ b/changelog.md @@ -63,6 +63,7 @@ v1.0.0 - [2925](https://github.com/RuminantFarmSystems/RuFaS/pull/2925) - [minor change] [NoInputChange] [NoOutputChange] Fix the `graph_and_report` option in report_generation.py. - [2907](https://github.com/RuminantFarmSystems/RuFaS/pull/2907) - [minor change] [NoInputChange] [OutputChange] Fix the FarmGrownFeed Emissions unit issue. The mirror issue of [Fix FarmGrownFeed Emissions Unit on test #2908](https://github.com/RuminantFarmSystems/MASM/pull/2908) to update `dev`. - [2934](https://github.com/RuminantFarmSystems/RuFaS/pull/2934) - [minor change] [NoInputChange] [NoOutputChange] [Animal][Reproduction] Refactor `Reproduction.execute_cow_ed_protocol()`. +- [2940](https://github.com/RuminantFarmSystems/RuFaS/pull/2940) - [minor change] [NoInputChange] [NoOutputChange] update github actions to hold automated checks until the PR is no longer a draft. ### v1.0.0 From 4a0c9cec3ba6f6b1e82779e2b33e424fe77ee16f Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Fri, 10 Apr 2026 12:42:23 -0500 Subject: [PATCH 6/7] re-enable manual job exec. --- .github/workflows/combined_format_lint_test_mypy.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index c902dcba54..0884d6062f 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -13,13 +13,15 @@ env: jobs: fail_if_pull_request_is_draft: - if: github.event.pull_request.draft == true + name: Draft PR Chek + if: ${{ github.event.pull_request.draft == true }} runs-on: ubuntu-latest steps: - name: Fails in order to indicate that PR needs to be marked as ready to review and other checks passed. run: exit 1 # don't run other jobs format_code: - if: github.event.pull_request.draft == false + name: Format Code + if: ${{ github.event.action == 'workflow_dispatch' || github.event.pull_request.draft == false }} runs-on: ubuntu-latest outputs: changelog_updated: ${{ steps.record_if_changelog_updated.outputs.is_changelog_updated }} @@ -176,7 +178,7 @@ jobs: lint_test_type_check: name: Lint, Test, Coverage, and Type Checking - if: github.event.pull_request.draft == false + if: ${{ github.event.action == 'workflow_dispatch' || github.event.pull_request.draft == false }} needs: format_code runs-on: ubuntu-latest steps: From 0976cd2927182a5fd7c38d38ce13537d058a03dd Mon Sep 17 00:00:00 2001 From: Clay Morrow <25436787+morrowcj@users.noreply.github.com> Date: Tue, 14 Apr 2026 13:43:31 -0500 Subject: [PATCH 7/7] remove failing check - just skip on draft --- .github/workflows/combined_format_lint_test_mypy.yml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/.github/workflows/combined_format_lint_test_mypy.yml b/.github/workflows/combined_format_lint_test_mypy.yml index 0884d6062f..44755fc694 100644 --- a/.github/workflows/combined_format_lint_test_mypy.yml +++ b/.github/workflows/combined_format_lint_test_mypy.yml @@ -12,13 +12,6 @@ env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} jobs: - fail_if_pull_request_is_draft: - name: Draft PR Chek - if: ${{ github.event.pull_request.draft == true }} - runs-on: ubuntu-latest - steps: - - name: Fails in order to indicate that PR needs to be marked as ready to review and other checks passed. - run: exit 1 # don't run other jobs format_code: name: Format Code if: ${{ github.event.action == 'workflow_dispatch' || github.event.pull_request.draft == false }}