-
Notifications
You must be signed in to change notification settings - Fork 8
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
Check for existence of backport branch before trying to create it #125
Conversation
yardenshoham
commented
Apr 3, 2024
- Fixes (?) Done tracking with multiple branches #124
Let's try it Signed-off-by: Yarden Shoham <git@yardenshoham.com>
Do we read the |
gitea-backporter/src/github.ts Line 22 in e863e8b
|
Hmm I think we may have to remove the
So the mechanism will work as long as the bot does both backports in the same run, but that likely can not be guaranteed, right? |
I guess above could be fixed if |
The bot never sets a backport/done when there is more than 1 backport/v* label |
gitea-backporter/src/github.ts Lines 424 to 431 in e863e8b
|
Hmm I think that is the problem, it should have set |
I could give it a shot next week |
I think my suggestion with the branch was bad because a backport is only truly done once the PR exists, the branch creation is just one of the steps. |
That's the same thing anyway, we only push if the cherry-pick succeeds |
Here's a pseudo-code how I would do it:
|
Only question is whether GH API can help with "check if pr exists", e.g. determine PR number from branch name alone, likely there must be some way. |
I don't think this fix was right and it shouldn't have merged imho. |
This fix is correct but causes too many API calls, which leads to rate limiting. The easiest solution I can think of is memorization of the |