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

276: Merge style PRs should generate "merge" webrevs #501

Closed
wants to merge 3 commits into from

Conversation

rwestberg
Copy link
Member

@rwestberg rwestberg commented Mar 6, 2020

Hi all,

Please review this change that for merge style PRs generate webrevs only containing the changes done in the merge commit.

Note that this is only a partial implementation, such webrevs should also be generated if there are further commits pushed to the PR.

Best regards,
Robin


Progress

  • Change must not contain extraneous whitespace
  • Change must be properly reviewed

Issue

  • SKARA-276: Merge style PRs should generate "merge" webrevs

Reviewers

  • Erik Helin (ehelin - Reviewer) ⚠️ Review applies to 7c657ee

Download

$ git fetch https://git.openjdk.java.net/skara pull/501/head:pull/501
$ git checkout pull/501

@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Mar 6, 2020

👋 Welcome back rwestberg! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request.

@mlbridge
Copy link

@mlbridge mlbridge bot commented Mar 6, 2020

Webrevs

edvbld
edvbld approved these changes Mar 18, 2020
Copy link
Member

@edvbld edvbld left a comment

Looks good!

var mergeCommit = localRepo.lookup(head);
if (mergeCommit.isEmpty()) {
return Optional.empty();
}
if (!mergeCommit.get().isMerge()) {
return Optional.empty();
}
return mergeCommit;
Copy link
Member

@edvbld edvbld Mar 18, 2020

Choose a reason for hiding this comment

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

Suggested change
var mergeCommit = localRepo.lookup(head);
if (mergeCommit.isEmpty()) {
return Optional.empty();
}
if (!mergeCommit.get().isMerge()) {
return Optional.empty();
}
return mergeCommit;
return localRepo.lookup(head).filter(c -> c.isMerge());

@openjdk
Copy link

@openjdk openjdk bot commented Mar 18, 2020

@rwestberg This change now passes all automated pre-integration checks. When the change also fulfills all project specific requirements, type /integrate in a new comment to proceed. After integration, the commit message will be:

276: Merge style PRs should generate "merge" webrevs

Reviewed-by: ehelin
  • If you would like to add a summary, use the /summary command.
  • To credit additional contributors, use the /contributor command.
  • To add additional solved issues, use the /solves command.

Since the source branch of this PR was last updated there have been 16 commits pushed to the master branch. Since there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid automatic rebasing, please merge master into your branch, and then specify the current head hash when integrating, like this: /integrate b180754072ad58a89567f9df4f21ee205f88108f.

➡️ To integrate this PR with the above commit message, type /integrate in a new comment.

@openjdk openjdk bot added the ready label Mar 18, 2020
@rwestberg
Copy link
Member Author

@rwestberg rwestberg commented Mar 18, 2020

/integrate

@openjdk openjdk bot closed this Mar 18, 2020
@openjdk openjdk bot added integrated and removed ready rfr labels Mar 18, 2020
@openjdk
Copy link

@openjdk openjdk bot commented Mar 18, 2020

@rwestberg The following commits have been pushed to master since your change was applied:

  • b180754: 315: Publish command is not in GitSkara.java
  • 6c1dd66: 319: git-info uses wrong JBS project
  • 4b7b969: 292: Add comment to PR when it becomes outdated
  • c0abd82: 317: git-webrev uses wrong JBS links for commit messages
  • 0d08b36: 310: RFR thread integration messages should check target branch
  • 6468f17: 309: Backport creation fails
  • 27793d2: Make the notifier retry logic more granular
  • 286ccf8: 301: Keep track of branch progress per notifier
  • d0eb797: git-webrev: use HEAD when branch has no commits
  • a2a2237: 302: PR body updater should use .jcheck/conf from target branch
  • bfa006e: 296: git webrev fails
  • 628185b: 262: Unresolved CSR should not cause jcheck to fail or rfr label to be removed
  • 8bd03e3: Allow reading the resolution property in Jira issues
  • 1b19054: csr: add logging
  • 9f69a8b: csr: avoid null pointer exceptions
  • 3d52e6b: Wait with resolving PR until needed when bridging mails

Your commit was automatically rebased without conflicts.

Pushed as commit d45b816.

@mlbridge
Copy link

@mlbridge mlbridge bot commented Mar 18, 2020

Mailing list message from Robin Westberg on skara-dev:

Changeset: d45b816
Author: Robin Westberg <rwestberg at openjdk.org>
Date: 2020-03-18 11:41:56 +0000
URL: https://git.openjdk.java.net/skara/commit/d45b8161

276: Merge style PRs should generate "merge" webrevs

Reviewed-by: ehelin

! bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/ArchiveItem.java
! bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/ArchiveMessages.java
! bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/ArchiveWorkItem.java
+ bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/WebrevDescription.java
! bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/WebrevNotification.java
! bots/mlbridge/src/main/java/org/openjdk/skara/bots/mlbridge/WebrevStorage.java
! bots/mlbridge/src/test/java/org/openjdk/skara/bots/mlbridge/MailingListBridgeBotTests.java
! bots/mlbridge/src/test/java/org/openjdk/skara/bots/mlbridge/WebrevStorageTests.java
! webrev/src/main/java/org/openjdk/skara/webrev/Webrev.java

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