Skip to content

Github/pullrequest action using merge.strategy: client with after: 0m — "Pull Request is not mergeable" error in clean stage after successful merge #9003

Description

@perlan

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

When using merge.strategy: client (with any after value that allows immediate merging, e.g. after: 0m), the action correctly creates and merges the pull request, but the run still ends with an error during the clean stage:

ERROR: Failed to clean up action(s): merging pull request: Pull Request is not mergeable
ERROR: - merging pull request: Pull Request is not mergeable
ERROR: cleaning action stage: "failed to clean up action(s):\n\tmerging pull request: Pull Request is not mergeable"

Expected Behavior

updatecli pipeline apply should create and merge the pull request with out any error

Steps To Reproduce

actions:
  myAction:
    kind: github/pullrequest
    scmID: myGithub
    spec:
      merge:
        strategy: client
        after: 0m

Run updatecli pipeline apply. The pull request is created and merged successfully, but the run exits with the error above.

Environment

- OS:Tested on macOS and GitHub action workflow using ubuntu
- updatecli: v0.117.1

Pipeline Graph

No response

OpenTelemetry Trace

No response

Anything else?

Looking through the code in pullrequest.go, it seems like the error is coming from CleanAction that calls mergeAfterDuration() on a PR that was already merged by CreateAction.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions