Skip to content

Add automerge and autoupdate labels to backport PRs #1307

Closed

Description

@sicoyle

Backport PRs opened by dapr-bot don't consistently carry the automerge and autoupdate labels. Some release-1.19 backports have them because someone added them by hand (#1268, #1270, #1272), and others have none (#1288, #1290, #1291, #1292, #1293, #1294, #1295), so they wait until a maintainer notices and labels them.

The shared backport workflow in dapr/.github already supports this through its labels-template input, which defaults to []. Our caller in .github/workflows/backport.yaml doesn't set it. The fix is to pass it:

jobs:
  backport:
    uses: dapr/.github/.github/workflows/backport.yaml@main
    with:
      labels-template: '["automerge", "autoupdate"]'
    secrets:
      dapr_bot_token: ${{ secrets.DAPR_BOT_TOKEN }}

The labels are only applied to backports that cherry-pick cleanly. When the cherry-pick conflicts, the bot opens a placeholder PR with a failing backport/conflict status and no labels, and whoever resolves it adds them. That's fine and out of scope here.

To verify after merging, add backport release-1.19 to a merged PR and check that the backport PR the bot opens has both labels.

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions