Comments (2)
We're having a very similar issue (though, a slightly different error) with the zope packages, which pip-tools 6.5.0+ (and thus dependabot) are now normalising from zope.interface
to zope-interface
. A minimal repro is:
python3 -m venv liccheck-test
. liccheck-test/bin/activate
pip install liccheck
echo 'zope-interface' > requirements.txt
pip install -r requirements.txt
echo '[Licenses]
authorized_licenses:
zope public' > licenses.ini
liccheck -s licenses.ini -l cautious -r requirements.txt --no-deps
Which has the following output:
gathering licenses...
Traceback (most recent call last):
File "/Users/cdestigter/liccheck-test/bin/liccheck", line 8, in <module>
sys.exit(main())
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 344, in main
sys.exit(run(args))
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 339, in run
return process(args.requirement_txt_file, strategy, args.level, args.reporting_txt_file, args.no_deps)
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 249, in process
pkg_info = get_packages_info(requirement_file, no_deps)
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 165, in get_packages_info
packages = [transform(dist) for dist in resolve_func(requirements)]
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 165, in <listcomp>
packages = [transform(dist) for dist in resolve_func(requirements)]
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 119, in transform
licenses = get_licenses_from_classifiers(dist) or get_license(dist) or []
File "/Users/cdestigter/liccheck-test/lib/python3.9/site-packages/liccheck/command_line.py", line 145, in get_licenses_from_classifiers
if dist.has_metadata(dist.PKG_INFO):
AttributeError: 'NoneType' object has no attribute 'has_metadata'
from python-license-check.
This has now been resolved upstream in setuptools (pypa/setuptools#3153) and is no longer an issue with setuptools >= 62.0.0
.
from python-license-check.
Related Issues (20)
- `or`-ed license check breaks on licenses with "or" in the name HOT 6
- specifying a non-existant strategy file produces no error or warning
- liccheck doesn't notice project licenses in pyproject.toml HOT 1
- DeprecationWarning: pkg_resources is deprecated as an API HOT 1
- Support Python 3.12
- Provide Support for Poetry Dependency Groups
- Error when handling normalised names for package extras
- Editable requirements (-e) raises "DistributionNotFound: The 'None' distribution was not found"
- support pre-commit hook HOT 1
- pre-commit hooks is not working as expected HOT 3
- pkg_resources.VersionConflict: (pandas 1.3.5 (~/miniconda3/envs/myenv/lib/python3.8/site-packages), Requirement.parse('pandas==1.3.3')) HOT 1
- Order licenses alphabetically
- Feature Request: Option To Specify Where To Look for License Information
- authorized_packages doesn't work in pyproject.toml HOT 1
- Improve error message in case a requirement is not installed.
- DistributionNotFound: The 'greenlet==1.1.3' distribution was not found and is required by the application HOT 3
- Allow matching with regex
- Dependency Dashboard
- Action Required: Fix Renovate Configuration
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from python-license-check.