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

Fix force push to develop on master hotfixes #930

Merged
merged 1 commit into from
Oct 2, 2023

Conversation

bdmendes
Copy link
Member

@bdmendes bdmendes commented Sep 1, 2023

Review checklist

  • Terms and conditions reflect the current change
  • Contains enough appropriate tests
  • If aimed at production, writes a new summary in whatsnew/whatsnew-pt-PT
  • Properly adds an entry in changelog.md with the change
  • If PR includes UI updates/additions, its description has screenshots
  • Behavior is as expected
  • Clean, well-structured code

@bdmendes bdmendes force-pushed the fix-master-hotfix-action branch 5 times, most recently from 569aed1 to 7f10958 Compare September 1, 2023 14:22
LuisDuarte1
LuisDuarte1 previously approved these changes Sep 1, 2023
Copy link
Member

@LuisDuarte1 LuisDuarte1 left a comment

Choose a reason for hiding this comment

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

LGTM, just check if the push force permission is only on the @niaefeup-admin account on the develop branch

@LuisDuarte1 LuisDuarte1 self-requested a review September 1, 2023 14:48
@LuisDuarte1 LuisDuarte1 dismissed their stale review September 1, 2023 14:49

We should discuss some changes that must be done by fixes to master

Copy link
Member

@LuisDuarte1 LuisDuarte1 left a comment

Choose a reason for hiding this comment

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

I dismissed the review, because I have some further thoughts into this to make fixes into master simpler. Also maybe we should look into not bumping the minor version on master if the push doesn't come from develop, and instead bump the patch version.

Comment on lines +37 to +46
git fetch origin develop
if [[ $(git diff --quiet HEAD~1 origin/develop) ]]; then
echo "Master version does not match develop version"
Copy link
Member

Choose a reason for hiding this comment

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

Maybe if the master does not match the develop branch, we should create automatically create a PR to accommodate such fixes to the develop branch

Copy link
Member

Choose a reason for hiding this comment

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

In this way we can adopt the fix workflow that we discussed in the past Thursday meeting:

  1. Make fix on the master branch
  2. Make a PR into the master branch
  3. Upon merging, the action will automatically create a PR to merge this changes into develop
  4. If necessary, do some fixes to work in the develop branch
  5. Upon approval, merge into develop

I think this is the most streamlined and error-free approach into getting fixes done in master but also in develop.
Maybe this should be a seperate action workflow, and maybe done on a seperate issue, that listens to merged pull request events into `master, wdyt?

Copy link
Member Author

Choose a reason for hiding this comment

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

Sure, we can create a separate workflow listening for merged pull requests to master or simply pushes, that compares to develop and finds if it needs backporting. I think that should go on another issue since it is not related to this hotfix.

Copy link
Member

@LuisDuarte1 LuisDuarte1 Sep 1, 2023

Choose a reason for hiding this comment

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

With that said, maybe you should change the base of this PR to master and not to develop 😅
Just to be consistent with this workflow, from now on.

@codecov
Copy link

codecov bot commented Oct 2, 2023

Codecov Report

Merging #930 (e21a273) into master (c49573c) will not change coverage.
Report is 2 commits behind head on master.
The diff coverage is n/a.

Additional details and impacted files
@@          Coverage Diff          @@
##           master   #930   +/-   ##
=====================================
  Coverage      23%    23%           
=====================================
  Files         143    143           
  Lines        4351   4351           
=====================================
  Hits          959    959           
  Misses       3392   3392           

@bdmendes bdmendes merged commit 00877f1 into master Oct 2, 2023
6 checks passed
@bdmendes bdmendes deleted the fix-master-hotfix-action branch October 2, 2023 12:02
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.

2 participants