Skip to content

fix: prevent duplicate security review comments on PRs#78

Open
0x48core wants to merge 2 commits intoanthropics:mainfrom
0x48core:fix/deduplicate-security-review-comments
Open

fix: prevent duplicate security review comments on PRs#78
0x48core wants to merge 2 commits intoanthropics:mainfrom
0x48core:fix/deduplicate-security-review-comments

Conversation

@0x48core
Copy link

@0x48core 0x48core commented Mar 3, 2026

Two issues caused duplicate security comments to appear on PRs:

  1. No concurrency control — parallel workflow runs on the same PR would
    both see zero existing comments and post the same findings. Added a
    concurrency group keyed by PR number with cancel-in-progress.

  2. Missing pagination — the existing comments check used the default
    page size (30), so security comments beyond page 1 were invisible.
    Replaced with a paginated fetch helper (ghApiAll) that retrieves all
    comments.

Also replaced the all-or-nothing deduplication with per-finding
fingerprinting (file:line:message) so genuinely new findings on later
commits still get posted while true duplicates are skipped.

@0x48core
Copy link
Author

0x48core commented Mar 3, 2026

@ddworken @GrahamCampbell @Eduard-Voiculescu could you review my PR, thank you so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants