File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 3737 echo "Meeting week detected. Proceeding to notify open PRs."
3838
3939 REPO="${{ github.repository }}"
40- PR_LIST =$(gh pr list --repo $REPO --state open --json number --jq '.[].number' )
40+ PR_DATA =$(gh pr list --repo $REPO --state open --json number,author,createdAt )
4141
42- if [ -z "$PR_LIST " ]; then
42+ if [ -z "$PR_DATA" ] || [ "$PR_DATA" = "[] " ]; then
4343 echo "No open PRs found."
4444 exit 0
4545 fi
5959 EOF
6060 )
6161
62- for PR_NUM in $PR_LIST ; do
63- echo "Processing PR #$PR_NUM"
62+ echo "$PR_DATA" | jq -r 'group_by(.author.login) | .[] | sort_by(.createdAt) | reverse | .[0] | .number' | while read PR_NUM ; do
63+ echo "Processing most recent PR #$PR_NUM for user "
6464
6565 ALREADY_COMMENTED=$(gh pr view $PR_NUM --repo $REPO --json comments --jq '.comments[].body' | grep -F "Office Hour Bot" || true)
6666
Original file line number Diff line number Diff line change @@ -54,6 +54,7 @@ This changelog is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.
5454- Added advanced issue template for contributors ` .github/ISSUE_TEMPLATE/06_advanced_issue.yml ` .
5555
5656### Changed
57+ - Reduce office-hours reminder spam by posting only on each user's most recent open PR, grouping by author and sorting by creation time (#1121 )
5758- Pylint cleanup for token_airdrop_transaction_cancel.py (#1081 ) [ @tiya-15 ] ( https://github.com/tiya-15 )
5859- Move ` account_allowance_delete_transaction_hbar.py ` from ` examples/ ` to ` examples/account/ ` for better organization (#1003 )
5960- Improved consistency of transaction examples (#1120 )
You can’t perform that action at this time.
0 commit comments