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

feat(github): update pr baseBranch #22663

Merged
merged 7 commits into from Jun 17, 2023

Conversation

RahulGautamSingh
Copy link
Collaborator

@RahulGautamSingh RahulGautamSingh commented Jun 9, 2023

Changes

  • update base of an existing update PR when baseBranch is changed in config

Context

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@RahulGautamSingh
Copy link
Collaborator Author

RahulGautamSingh commented Jun 9, 2023

Reproduction:
RahulGautamSingh-testing/update-base-branch#3 (baseBranch changed in config)
RahulGautamSingh-testing/update-default-branch-0#1 (defaultBranch changed)

@RahulGautamSingh RahulGautamSingh requested review from rarkins and viceice and removed request for rarkins June 9, 2023 22:38
@RahulGautamSingh RahulGautamSingh marked this pull request as ready for review June 9, 2023 22:39
Copy link
Member

@viceice viceice left a comment

Choose a reason for hiding this comment

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

we need to save the original base branch inside cache or body struct, so we can detect a manual changed PR target by users and don't overwite it.

we also need to open follow up PR's for other platforms.

@RahulGautamSingh
Copy link
Collaborator Author

RahulGautamSingh commented Jun 12, 2023

we need to save the original base branch inside cache or body struct, so we can detect a manual changed PR target by users and don't overwite it.

Already done here: #21724

we also need to open follow up PR's for other platforms.

Working on it.

Copy link
Collaborator

@rarkins rarkins left a comment

Choose a reason for hiding this comment

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

The basic use case works as expected, however the logs are misleading:

DEBUG: Processing existing PR (repository=renovate-reproductions/22663, branch=renovate/node-18.x)
DEBUG: PR body changed (repository=renovate-reproductions/22663, branch=renovate/node-18.x)
       "prTitle": "Update Node.js to v18.16.0"
DEBUG: updatePr(1, Update Node.js to v18.16.0, body) (repository=renovate-reproductions/22663, branch=renovate/node-18.x)
DEBUG: PR updated...prNo: 1 (repository=renovate-reproductions/22663, branch=renovate/node-18.x)
 INFO: PR updated (repository=renovate-reproductions/22663, branch=renovate/node-18.x)
       "pr": 1,
       "prTitle": "Update Node.js to v18.16.0"

There's not a single mention of the old base branch or what's going on. Can you print an explicit message which says "PR base branch has changed" or something similar?

@rarkins rarkins added this pull request to the merge queue Jun 17, 2023
Merged via the queue into renovatebot:main with commit 4665f1d Jun 17, 2023
36 checks passed
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 35.126.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prevent renovate from ever merging PRs
4 participants