Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Let groovy know whether github hasn't checked the mergeability of a pull request #128

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

LaszloAshin
Copy link

@LaszloAshin LaszloAshin commented Aug 30, 2024

The mergeable flag can be null while github hasn't yet decided if the PR is mergeable or not.

See https://github.com/eclipse-egit/egit-github/blob/a30aa361f65d5ccbaca1aedd12651ff2636a3ed9/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/PullRequest.java#L98-L99
See https://docs.github.com/en/rest/pulls/pulls?apiVersion=2022-11-28#get-a-pull-request

Testing done

I tested this manually on a local jenkins instance. I couldn't make github return a response with missing mergeable flag but I made sure that my change doesn't break the normal workflow when the flag is present with a value of true or false.

I also added an integration test that runs automatically.

Submitter checklist

  • Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or Jira
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Ensure you have provided tests - that demonstrates feature works or fixes the issue

@LaszloAshin LaszloAshin changed the title Allow null for isMergeable() Allow null for isMergeable() Sep 2, 2024
@LaszloAshin LaszloAshin changed the title Allow null for isMergeable() Let groovy know whether github hasn't checked the mergeability of a pull request Sep 6, 2024
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