Skip to content

Conversation

@anithapriyanatarajan
Copy link
Contributor

@anithapriyanatarajan anithapriyanatarajan commented Dec 12, 2025

Changes

This replaces the Prow Tide mechanism with native GitHub workflows and merge queue functionality. The new system provides:

  • Label-based approval via /lgtm and /approve commands
  • Hold mechanism via /hold command
  • Automatic WIP detection
  • Release note label enforcement
  • Merge conflict detection
  • Required status check for merge readiness

All workflows are organized in .github/workflows/merge-automation/ for better organization.

Benefits over Prow Tide:

  • Event-driven (immediate response vs 2m polling)
  • No infrastructure to maintain
  • Native GitHub UI integration
  • Simpler permission model

Effort to address - #93

Submitter Checklist

As the author of this PR, please check off the items in this checklist:

  • Has Docs if any changes are user facing, including updates to minimum requirements e.g. Kubernetes version bumps
  • Has Tests included if any functionality added or changed
  • pre-commit Passed
  • Follows the commit message standard
  • Meets the Tekton contributor standards (including functionality, content, code)
  • Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
  • Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings). See some examples of good release notes.
  • Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes

NONE

/kind misc

Assisted-by: Claude-sonnet

@tekton-robot tekton-robot added the kind/misc Categorizes issue or PR as a miscellaneuous one. label Dec 12, 2025
@tekton-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
To complete the pull request process, please ask for approval from anithapriyanatarajan after the PR has been reviewed.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@tekton-robot tekton-robot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Dec 12, 2025
@anithapriyanatarajan anithapriyanatarajan changed the title chore: add GitHub merge queue workflows to replace Prow Tide WIP chore: add GitHub merge queue workflows to replace Prow Tide Dec 12, 2025
@tekton-robot tekton-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 12, 2025
@anithapriyanatarajan anithapriyanatarajan changed the title WIP chore: add GitHub merge queue workflows to replace Prow Tide chore: add GitHub merge queue workflows to replace Prow Tide Dec 12, 2025
@tekton-robot tekton-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Dec 12, 2025
@tekton-robot tekton-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 12, 2025
@anithapriyanatarajan anithapriyanatarajan force-pushed the workflow-lgtm branch 3 times, most recently from 47a1d9e to 44224ee Compare December 12, 2025 12:13
@tekton-robot tekton-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 12, 2025
@tekton-robot tekton-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 12, 2025
@anithapriyanatarajan anithapriyanatarajan changed the title chore: add GitHub merge queue workflows to replace Prow Tide WIP chore: add GitHub merge queue workflows to replace Prow Tide Dec 12, 2025
@tekton-robot tekton-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 12, 2025
@anithapriyanatarajan anithapriyanatarajan force-pushed the workflow-lgtm branch 4 times, most recently from 2b29b11 to 2a28f79 Compare December 12, 2025 13:41
This PR replaces the Prow Tide mechanism with native GitHub workflows
and merge queue functionality, providing equivalent approval and merge
automation without external infrastructure.

1. **approval-labels.yaml**: Handles /lgtm and /approve commands
   - Adds/removes lgtm and approved labels via PR comments
   - Permission checking using GitHub API
   - Only users with write access can approve

2. **hold-label.yaml**: Handles /hold and /unhold commands
   - Allows maintainers and PR authors to block PRs from merging
   - Adds/removes do-not-merge/hold label

3. **wip-label.yaml**: Automatic WIP detection
   - Detects [WIP], WIP:, [Draft], draft status, or 🚧 in PR titles
   - Auto-manages do-not-merge/work-in-progress label

4. **release-notes-label.yaml**: Release note enforcement
   - Requires release-note, release-note-action-required, or release-note-none
   - Blocks merge if missing release note label

5. **needs-rebase-label.yaml**: Merge conflict detection
   - Automatically detects merge conflicts
   - Manages needs-rebase label

6. **merge-readiness.yaml**: Required status check
   - Verifies both lgtm and approved labels are present
   - Blocks if any do-not-merge/* or needs-* labels exist
   - Single source of truth for merge eligibility

- **.github/github-merge-queue.md**: Complete documentation
  - Command reference for /lgtm, /approve, /hold
  - Workflow diagrams and architecture
  - Migration guide from Prow Tide
  - Setup instructions for merge queue

- **ci.yaml**: Removed unnecessary job dependencies
  - Unit tests, linting, and other checks now run in parallel
  - No longer wait for build job unnecessarily
  - Faster feedback on PRs

- **kind-e2e.yaml**: Added CI check dependency
  - E2E tests now wait for CI checks to pass on PRs
  - Prevents wasteful E2E runs on broken code
  - Push/merge_group events run immediately without waiting

-  Event-driven (immediate) vs polling (2m delay)
-  No infrastructure to maintain
-  Native GitHub UI integration
-  Simpler permission model
-  Better visibility with GitHub checks
-  Works with GitHub merge queue

- All existing Prow commands work identically: /lgtm, /approve, /hold
- Blocking labels have same effect: do-not-merge/*, needs-*
- Permission model uses GitHub repository access (write/admin)

Co-authored-by: Claude <claude@anthropic.com>
@anithapriyanatarajan
Copy link
Contributor Author

/retest

@anithapriyanatarajan
Copy link
Contributor Author

/retest

Copy link
Member

@vdemeester vdemeester left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is a good start, but could we make most of these as tools (or python scripts). The rational behind this, is to migrate them at some point in dogfooding as tasks. It could be done as follow-up though.

Comment on lines 34 to 90
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
with:
go-version-file: "go.mod"
- name: Run unit tests
run: |
go test -v -race ./pkg/... ./cmd/...
linting:
name: Linting
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
with:
go-version-file: "go.mod"
- name: Check Go formatting
run: |
gofmt_out=$(gofmt -d $(find * -name '*.go' ! -path 'vendor/*' ! -path 'third_party/*'))
if [[ -n "$gofmt_out" ]]; then
echo "$gofmt_out"
echo "ERROR: Go files are not formatted. Run 'go fmt ./...' to fix."
exit 1
fi
echo "All Go files are properly formatted."
- name: golangci-lint
uses: golangci/golangci-lint-action@1e7e51e771db61008b38414a730f564565cf7c20 # v9.2.0
with:
only-new-issues: true
args: --timeout=10m
- name: YAML Lint
run: |
sudo apt-get update && sudo apt-get install -y yamllint
yamllint -c .yamllint config/ .github/workflows/
continue-on-error: false

check-licenses:
name: License Check
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
with:
go-version-file: "go.mod"
- name: Check licenses
run: |
go install github.com/google/go-licenses@v1.6.0
go-licenses check ./...
ko-resolve:
name: Ko Resolve (Multi-arch)
needs: [build]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why removing those ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/misc Categorizes issue or PR as a miscellaneuous one. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants