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

cli: add git-upgrade-requirements #743

Merged
merged 2 commits into from
Oct 10, 2023

Conversation

mdonadoni
Copy link
Member

Closes #741

@codecov
Copy link

codecov bot commented Sep 12, 2023

Codecov Report

Merging #743 (d4db226) into master (61fdde9) will increase coverage by 0.06%.
The diff coverage is 21.91%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #743      +/-   ##
==========================================
+ Coverage   18.87%   18.93%   +0.06%     
==========================================
  Files          26       26              
  Lines        2199     2271      +72     
==========================================
+ Hits          415      430      +15     
- Misses       1784     1841      +57     
Files Coverage Δ
reana/config.py 100.00% <100.00%> (ø)
reana/reana_dev/utils.py 38.30% <4.34%> (-2.14%) ⬇️
reana/reana_dev/git.py 29.50% <23.91%> (-0.65%) ⬇️

@mdonadoni
Copy link
Member Author

What should we do regarding feature branch creation/management? Currently git-upgrade-shared-modules and git-upgrade-requirements need to be run in a repository where the current branch is a feature branch, and they will fail if the branch is master.

Instead git-create-release-commit creates a new branch release-1.2.3, but this command is usually executed as last when making a new release: first the shared modules are updated, then all the dependencies in requirements.txt are updated (if needed), and finally the release commit is created.

Should we change git-upgrade-shared-modules/git-upgrade-requirements to also create a new feature branch? Which name should they use? Or should we create a new git-create-release-branch command?

@giuseppe-steduto
Copy link
Member

Should we change git-upgrade-shared-modules/git-upgrade-requirements to also create a new feature branch?

I'd say that these commands would mainly be run:

  • either during the normal development process, case in which we would very likely already be on a feature branch
  • or during the release process, case in which it would make sense to use the release-1.2.3 branch.

Maybe a nice idea could be adding a flag to git-create-release-commit (to also call the git-upgrade-requirements command), or viceversa, add a flag to the upgrade requirements command (to also create the release commit and branch).

What do you think?

/cc @tiborsimko

Copy link
Member

@giuseppe-steduto giuseppe-steduto left a comment

Choose a reason for hiding this comment

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

Looks good!

reana/reana_dev/utils.py Outdated Show resolved Hide resolved
@mdonadoni mdonadoni force-pushed the upgrade-requirements branch 3 times, most recently from 2b8693f to 332a019 Compare October 2, 2023 11:40
@mdonadoni
Copy link
Member Author

Maybe a nice idea could be adding a flag to git-create-release-commit (to also call the git-upgrade-requirements command), or viceversa, add a flag to the upgrade requirements command (to also create the release commit and branch).

What do you think?

I tried this approach, but it felt like those commands were getting quite complicated. In the end I have created a new git-create-release-branch command, and we could maybe group all the release-related commands in an (yet) another git-prepare-release command, that invokes all the others in the correct order?

@giuseppe-steduto
Copy link
Member

giuseppe-steduto commented Oct 3, 2023

we could maybe group all the release-related commands in an (yet) another git-prepare-release command, that invokes all the others in the correct order?

Sounds good to me! Do you want to address this here or in another issue?

@mdonadoni mdonadoni marked this pull request as ready for review October 6, 2023 13:26
@mdonadoni
Copy link
Member Author

Sounds good to me! Do you want to address this here or in another issue?

Let's do it in another issue/PR, this one is already quite big!

@mdonadoni mdonadoni merged commit d4db226 into reanahub:master Oct 10, 2023
14 checks passed
@mdonadoni mdonadoni deleted the upgrade-requirements branch October 26, 2023 06:58
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.

reana-dev: add command to update requirements.txt
2 participants