Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/duplicate-code-detector.lock.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions .github/workflows/duplicate-code-detector.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,12 @@ cat containers/api-proxy/proxy-utils.js 2>/dev/null | head -60

## Phase 5: Check for Existing Issues

Before filing new issues, check what's already been reported:
Before filing new issues, check BOTH open AND closed issues:

1. Search for open issues with `[Duplicate Code]` prefix using the GitHub toolset
2. Also search for issues with labels `code-quality` or `refactoring` that describe duplication
1. Search for issues with `[Duplicate Code]` prefix using the GitHub toolset with `state: all` (or equivalent `is:open` + `is:closed`)
2. Also search for issues with labels `code-quality` or `refactoring` that describe duplication using `state: all` (or equivalent `is:open` + `is:closed`)
3. Skip any finding that already has an open tracking issue
4. For matching closed issues, check the GitHub `state_reason`: **auto-skip only when `state_reason` is `not_planned`** (often shown as "won't fix" / "not planned"). If `state_reason` is `completed` and the finding still reproduces, reopen the prior issue or file a new one with fresh evidence and a link to the prior issue.

## Phase 6: Prioritize and Report Findings

Expand Down Expand Up @@ -213,7 +214,7 @@ Low / Medium / High
- **Be specific**: Always include file paths and line numbers in the evidence section
- **Be actionable**: Each issue should have a clear, implementable suggestion
- **Avoid noise**: Only file issues for genuine duplication with real maintenance impact — not cosmetic similarities
- **No duplicates**: Check existing open issues before creating new ones
- **No duplicates**: Check existing issues with `state: all`; only treat closed issues as terminal when `state_reason` is `not_planned`
- **Security awareness**: Flag duplicated security-critical logic (domain validation, ACL rules, capability management) with higher urgency
- **Cap at 5 issues**: File at most 5 issues per run to avoid flooding the tracker

Expand Down
Loading
Loading