mergeability / mergeable

🤖 All the missing GitHub automation 🙂 🙌
https://mergeable.us
GNU Affero General Public License v3.0
683 stars 116 forks source link

[Bug] Mergeable failing to request reviews and post comments on pull requests #724

Open DanielTsiang opened 1 year ago

DanielTsiang commented 1 year ago

Recently over the past few months I've noticed that Mergeable fails to request reviews and post comments on pull requests when it should do.

It was working last year, I haven't changed any of the mergeable.yml config but it's stopped working sometime this year for some unknown reason.

shine2lay commented 1 year ago

@DanielTsiang does it happen sporadically or all the time?

DanielTsiang commented 1 year ago

@shine2lay it hasn't been working all the time for a while now.

Here is a snippet of the relevant part of the mergeable.yml config to help with debugging:

version: 2
mergeable:
  - when: pull_request.opened, pull_request.edited, pull_request.reopened, pull_request.ready_for_review
    filter:
      - do: payload
        pull_request:
          draft:
            boolean:
              match: false
    validate:
      - do: changeset
        must_include:
          regex: '^(dir-1)\/(?<service>service-1|service-2|service-3)\/(\k<service>)(\.env)$'
        files:
          added: true
          modified: true
          deleted: true
    pass:
      - do: comment
        payload:
          body: >
            The relevant team will need to control merging this PR.

            @relevant-team: please review this PR.
  - when: pull_request.opened, pull_request.edited, pull_request.reopened, pull_request.labeled, pull_request.unlabeled, pull_request.synchronize
    validate:
      - do: changeset
        must_include:
          regex: '.*/.env'
          message: 'Contains env changes...'
        files:
          added: true
          modified: true
          deleted: true
    pass:
      - do: request_review
        reviewers: ['user1']