Files
bun.sh/scripts
robobun 1de4448425 Fix duplicate issue bot to respect 👎 reactions and not re-close reopened issues (#24203)
## Summary

Fixed two bugs in the auto-close-duplicates bot:

- **Respect 👎 reactions from ANY user**: Previously only the issue
author's thumbs down would prevent auto-closing. Now any user can
indicate disagreement with the duplicate detection.
- **Don't re-close reopened issues**: The bot now checks if an issue was
previously reopened and skips auto-closing to respect user intent.

## Changes

1. Modified `fetchAllReactions` call to check all reactions, not just
the author's
2. Changed `authorThumbsDown` logic to `hasThumbsDown` (checks any
user's reaction)
3. Added `wasIssueReopened()` function to query issue events timeline
4. Added check to skip issues with "reopened" events in their history

## Test plan

- [ ] Manually test the script doesn't close issues with 👎 reactions
from non-authors
- [ ] Verify reopened issues are not auto-closed again
- [ ] Check that legitimate duplicates without objections still get
closed properly

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Bot <claude-bot@bun.sh>
Co-authored-by: Claude <noreply@anthropic.com>
2025-10-29 15:41:44 -07:00
..
2024-10-25 23:50:12 -07:00
2025-08-14 14:44:47 -07:00
2025-01-16 22:40:39 -08:00
2024-12-12 03:21:56 -08:00
2025-09-14 18:48:26 -07:00
fmt
2025-09-12 17:24:47 -07:00
2024-08-27 14:13:21 -07:00
2025-07-10 00:10:43 -07:00
2024-06-14 14:52:20 -07:00
2024-12-12 03:21:56 -08:00