scancode-toolkit
scancode-toolkit copied to clipboard
Fix #4568: Correct MPL-2.0 badge rule to prevent false positives on I…
Fixes #4568
What was wrong
ScanCode identified MPL-2.0 in README.md of dnspython v2.6.1 due to an overly broad
MPL badge rule (mpl-2.0_url_badge.RULE). The rule matched non-MPL badges such as
the ISC license badge, causing a false-positive detection.
What I did
- Updated the MPL-2.0 badge rule to use explicit MPL-only references
- Removed overly generic matching patterns that overlapped with ISC badges
- Ensured the rule only matches intentional MPL-2.0 badge text
Testing
- Manually verified using dnspython v2.6.1: MPL-2.0 is no longer detected
- ISC badge detection remains correct
- MPL-related rule tests (
pytest -k "mpl") pass
Hi! This PR fixes the badge false detection issue #4568. Please review it @JustinWonjaePark