mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-06 02:48:13 +00:00
fix(cost-map-sync): keep the reconcile step green when arming auto-merge fails
A failed `gh pr merge --auto` in the fallback arm aborted the step under `set -e` before the warning and before `sync` was written, so every later tick went red on the same PR. The failure now prints a warning naming the PR for a human to merge and the tick carries on.
This commit is contained in:
parent
b2402f8abf
commit
d3ff59fd8a
1 changed files with 3 additions and 3 deletions
6
.github/workflows/cost-map-sync.yml
vendored
6
.github/workflows/cost-map-sync.yml
vendored
|
|
@ -72,10 +72,10 @@ jobs:
|
|||
SUCCESS,pass|SUCCESS,pass,skipping|SUCCESS,skipping)
|
||||
if gh pr merge "$number" --repo "$GITHUB_REPOSITORY" --merge --delete-branch; then
|
||||
echo "Merged sync PR #$number; the next scheduled run syncs from the merged registry."
|
||||
elif [ "$(jq -r .autoMergeRequest <<< "$pr")" = "null" ] \
|
||||
&& ! gh pr merge "$number" --repo "$GITHUB_REPOSITORY" --auto --merge --delete-branch; then
|
||||
echo "::warning::Sync PR #$number is green but the app can neither merge it nor arm auto-merge on $GITHUB_REF_NAME; a human has to merge it."
|
||||
else
|
||||
if [ "$(jq -r .autoMergeRequest <<< "$pr")" = "null" ]; then
|
||||
gh pr merge "$number" --repo "$GITHUB_REPOSITORY" --auto --merge --delete-branch
|
||||
fi
|
||||
echo "::warning::Sync PR #$number is green but the app is not a bypass actor on $GITHUB_REF_NAME; auto-merge is armed, so one approval lands it."
|
||||
fi
|
||||
;;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue