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

Order cherrypicking candidates by the closed date #34739

Merged
merged 1 commit into from
Oct 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions dev/README_RELEASE_AIRFLOW.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,7 @@ branch you can run:
./dev/airflow-github compare 2.1.2 --unmerged
```

Be careful and verify the hash commit specified. This is a 'best effort' to find it, and
could be inaccurate if the PR was referenced in other commits after it was merged. You can start
cherry picking from the bottom of the list. (older commits first)
You can start cherry picking from the bottom of the list. (older commits first)

When you cherry-pick, pick in chronological order onto the `vX-Y-test` release branch.
You'll move them over to be on `vX-Y-stable` once the release is cut. Use the `-x` option
Expand Down
4 changes: 3 additions & 1 deletion dev/airflow-github
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,9 @@ def compare(target_version, github_token, previous_version=None, show_uncherrypi
url="URL",
)
)

milestone_issues = sorted(
milestone_issues, key=lambda x: x.closed_at if x.closed_at else x.created_at, reverse=True
Copy link
Member

Choose a reason for hiding this comment

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

I didn't understand the need of reverse here:

(older commits first)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Just so I can cherrypick from the bottom of the list upwards. The last item would be the oldest

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The sorting is to get an order based on date then reverse it so that oldest commit is listed last

Copy link
Member

Choose a reason for hiding this comment

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

Okay, I see!

)
for issue in milestone_issues:
commit_in_main = get_commit_in_main_associated_with_pr(repo, issue)
status = issue.state.capitalize()
Expand Down