feat: add duplicate entry detection to site validation CI#2851
Open
mvanhorn wants to merge 1 commit intosherlock-project:masterfrom
Open
feat: add duplicate entry detection to site validation CI#2851mvanhorn wants to merge 1 commit intosherlock-project:masterfrom
mvanhorn wants to merge 1 commit intosherlock-project:masterfrom
Conversation
Adds a new step to the modified target validation workflow that checks for duplicate entries when new sites are added to data.json. Detects both case-insensitive name matches and shared urlMain domains against existing entries. Findings are prepended to the validation summary comment using the existing #### heading style. Fixes sherlock-project#2653 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds duplicate entry detection to
validate_modified_targets.yml. When new sites are added todata.json, the workflow now checks for:urlMaindomain as an existing entryChanges
A new "Check for duplicate entries" step runs inline Python between "Discover modified targets" and "Validate remote manifest". It compares new keys against the full existing manifest. Findings are written to
duplicate_findings.mdand prepended to the validation summary comment using the existing####heading style.Improvements over the previous attempt (#2658):
####headings matching existing formatTesting
The duplicate check is pure Python against two JSON files. It runs independently of the pytest validation steps and won't block PRs if it fails. The workflow only triggers on PRs that modify
data.json.Fixes #2653
This contribution was developed with AI assistance (Claude Code).