From 778b6008c3d32e6eb2c3e617d07acd5d5ad8f44f Mon Sep 17 00:00:00 2001 From: Yi Hu Date: Mon, 19 May 2025 11:38:08 -0400 Subject: [PATCH] Always trigger update Python dependency on manual run --- .github/workflows/update_python_dependencies.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/update_python_dependencies.yml b/.github/workflows/update_python_dependencies.yml index b98f88976553..d45aa2a08c91 100644 --- a/.github/workflows/update_python_dependencies.yml +++ b/.github/workflows/update_python_dependencies.yml @@ -77,12 +77,13 @@ jobs: - name: Commit Changes and create new PR env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GH_EVENT: ${{ github.event_name }} run: | # Take the current date, subtract from a release cut date in the past (Mar 6, 2024), # then get the num days % 42 (our release cadence is 42 days). # This will ensure it only runs the week after a release branch has been cut. days_diff=$(( ($(date +%s) - $(date --date="240306" +%s) )/(60*60*24)%42 )) - if [[ $days_diff -gt 6 ]]; then + if [[ $GH_EVENT != 'workflow_dispatch' && $days_diff -gt 6 ]]; then echo "Exiting early. We only update dependencies the week after we cut the release" exit 0 fi