Deterministically find license information for Python packages by checking PyPI metadata first, then falling back to Git repository LICENSE files using shallow cloning.
Limited to specific tools
Additional assets for this skill
This skill is limited to using the following tools:
scripts/find_license.pyThis skill helps you deterministically find license information for Python packages using a two-step approach: first checking PyPI metadata, then searching the source repository if needed.
When a user asks to find the license for a Python package, follow this deterministic process:
First, attempt to find the license from PyPI using the package inspection script:
./scripts/find_license.py <package_name> [version]
If the script finds a license in the PyPI metadata, stop here and return the license name.
If no license is found in PyPI metadata, search the package's source repository:
Skill: git:shallow-clone
find . -iname "license*" -o -iname "copying*" -o -iname "copyright*" | head -10
head -20 <license_file>
./scripts/find_license.py requests
Expected: Find "Apache-2.0" from PyPI metadata
./scripts/find_license.py some-package
Expected: Fall back to repository search if PyPI metadata is incomplete
./scripts/find_license.py django 4.2.0
Expected: Find license for specific Django version
This skill complements:
The skill focuses on finding license information, while license-checker focuses on assessing license compatibility for redistribution.