perf: decouple scheduled review comment sync
This commit is contained in:
parent
2379e34cdd
commit
db7448cd1e
31
.github/workflows/sweep.yml
vendored
31
.github/workflows/sweep.yml
vendored
@ -869,8 +869,37 @@ jobs:
|
||||
--path results/sweep-status \
|
||||
--rebase-strategy theirs
|
||||
|
||||
- name: Dispatch scheduled review comment sync
|
||||
if: ${{ success() && github.event_name == 'schedule' && needs.plan.outputs.hot_intake != 'true' }}
|
||||
env:
|
||||
GH_TOKEN: ${{ github.token }}
|
||||
TARGET_REPO: ${{ needs.plan.outputs.target_repo }}
|
||||
run: |
|
||||
set -euo pipefail
|
||||
item_numbers="$(pnpm run --silent workflow -- artifact-item-numbers --artifact-dir artifacts)"
|
||||
if [ -z "$item_numbers" ]; then
|
||||
echo "No review artifacts to sync comments for."
|
||||
exit 0
|
||||
fi
|
||||
for attempt in 1 2 3; do
|
||||
if gh workflow run sweep.yml \
|
||||
--ref main \
|
||||
-f target_repo="$TARGET_REPO" \
|
||||
-f apply_existing=true \
|
||||
-f apply_sync_comments_only=true \
|
||||
-f apply_item_numbers="$item_numbers" \
|
||||
-f apply_limit=0 \
|
||||
-f apply_comment_sync_min_age_days=7 \
|
||||
-f apply_progress_every=25; then
|
||||
echo "Dispatched scheduled comment sync for item numbers: $item_numbers"
|
||||
exit 0
|
||||
fi
|
||||
sleep "$((attempt * 10))"
|
||||
done
|
||||
echo "::warning::Unable to dispatch scheduled comment sync after three attempts; apply/comment-sync backstops can pick it up later."
|
||||
|
||||
- name: Sync selected review comments
|
||||
if: ${{ success() && (needs.plan.outputs.hot_intake != 'true' || github.event.inputs.item_number != '' || github.event.inputs.item_numbers != '') }}
|
||||
if: ${{ success() && (github.event_name != 'schedule' || needs.plan.outputs.hot_intake == 'true') && (needs.plan.outputs.hot_intake != 'true' || github.event.inputs.item_number != '' || github.event.inputs.item_numbers != '') }}
|
||||
timeout-minutes: 15
|
||||
env:
|
||||
GH_TOKEN: ${{ steps.target-write-token.outputs.token }}
|
||||
|
||||
@ -184,6 +184,12 @@ association, paired issue/PR state, snapshot drift, and repository profile
|
||||
rules. It closes only unchanged high-confidence proposals and otherwise updates
|
||||
or syncs the durable ClawSweeper review comment.
|
||||
|
||||
Scheduled normal review publishes records first, then dispatches durable review
|
||||
comment sync into the separate apply/comment-sync lane. This keeps slow GitHub
|
||||
comment writes from holding the normal review concurrency group and delaying the
|
||||
next 100-shard backfill wave. Exact and manual targeted review runs still sync
|
||||
their selected comments inline before finishing.
|
||||
|
||||
Long apply runs commit checkpoints and can dispatch continuation runs when they
|
||||
reach the configured close limit.
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user