Skip to content

Skip nightly wheel builds when no new commits exist#7

Merged
erwei-xilinx merged 1 commit into
amd:mainfrom
erwei-xilinx:skip-nightly-when-no-changes
Feb 27, 2026
Merged

Skip nightly wheel builds when no new commits exist#7
erwei-xilinx merged 1 commit into
amd:mainfrom
erwei-xilinx:skip-nightly-when-no-changes

Conversation

@erwei-xilinx

Copy link
Copy Markdown
Collaborator

Summary

  • The nightly cron was building and releasing wheels every day regardless of whether new commits had landed, causing duplicate wheels to accumulate in the latest-wheels release (e.g. commit 92550b1 was built on 4 consecutive days)
  • Adds a check-changes gate job that checks git log --since="25 hours ago" on schedule-triggered runs; if no new commits are found, the wheel build is skipped
  • All other triggers (PR, tag push, workflow_dispatch, merge_group) bypass the check and always build

Test plan

  • Verify the workflow YAML parses correctly (validated locally with yaml.safe_load)
  • Confirm PR/push/workflow_dispatch triggers still run the build (the check-changes job is skipped for non-schedule events, so needs.check-changes.result == 'skipped' evaluates to true)
  • Confirm a schedule trigger with no new commits skips the build
  • Confirm a schedule trigger with recent commits proceeds normally

🤖 Generated with Claude Code

The nightly cron was building and publishing wheels every day even when
no commits had landed, causing duplicate wheels to accumulate in the
latest-wheels release (e.g. the same commit built 4 days in a row).

Add a check-changes gate job that inspects git history for commits in
the last 25 hours. When triggered by schedule and no new commits are
found, the build-wheels job is skipped. All other triggers (PR, tag
push, workflow_dispatch, merge_group) bypass the check and always build.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@erwei-xilinx erwei-xilinx merged commit 8a68dee into amd:main Feb 27, 2026
8 of 9 checks passed
@erwei-xilinx erwei-xilinx deleted the skip-nightly-when-no-changes branch February 27, 2026 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant