Remove pluggy usage; replace the pluggy < 1.7.0 cap with direct entry-point loading
Maintainer thường phản hồi trong vòng 3 ngày
Chưa có ai nhận issue này.
- #5373 của @knowprasad — đã đóng, không merge
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 72/100
- Loại issue
- Tái cấu trúc
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- python
- Lĩnh vực
- backend, developer-experience
Hướng nghiên cứu
Inspect src/licensedcode/additional_license_location_provider.py and the pluggy constraints in pyproject.toml, pyproject-scancode-toolkit.toml, and pyproject-scancode-toolkit-mini.toml. Replace marker decoration and pluggy entry-point loading with importlib.metadata.entry_points(group="scancode_additional_license_location_provider"), then remove the pluggy cap after plugincode support is available. Run the relevant tests and verify providers are discovered and instantiated through the existing get_location() path.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Written by Claude Opus 5.5 via Claude Code for the scancode-toolkit maintainers; I prompted it, it did the work, I read it.
This is filed by Ronny Pfannschmidt, a pluggy maintainer. The behaviour scancode-toolkit relies on was never part of pluggy's API, and pluggy will not restore it.
Follow-up to #5363 and the cap in 1891da6acf. The root cause and the proposed fix are in aboutcode-org/plugincode#14. In short: plugincode decorates classes with hookspec and hookimpl markers, no hook is ever called, and pluggy serves only as an entry-point loader plus a {name: class} dict. pluggy 1.7 no longer accepts classes as hookspecs, so add_hookspecs raises at import time.
scancode-toolkit has two things to change:
- Its own copy of the pattern:
src/licensedcode/additional_license_location_provider.py.@location_provider_specdecorates theAdditionalLicenseLocationProviderPluginclass, followed byadd_hookspecs/load_setuptools_entrypoints/list_name_plugin. The plugin classes are then instantiated and called directly inget_location(). This can be replaced byimportlib.metadata.entry_points(group="scancode_additional_license_location_provider")now, without waiting for plugincode. - The cap:
pluggy >= 1.0.0, < 1.7.0inpyproject.toml,pyproject-scancode-toolkit.tomlandpyproject-scancode-toolkit-mini.toml. Once plugincode ships without pluggy, the pluggy dependency can be dropped here entirely rather than uncapped, because scancode-toolkit itself only imports pluggy in the file above.
- Ngôn ngữ chính
- Python
- Star
- 2.7k
- Fork
- 831
- Merge trung bình
- 3 ngày 4 giờ
- Pull request đã merge (30 ngày)
- 7
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của aboutcode-org/scancode-toolkit
-
bug: Unreachable JSON extension and format validation in validate_input_pathCó thể đã có người làm @0Cymantek0 đã nhận 18 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
aboutcode-org/scancode-toolkit#5351 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
CycloneDX output: metadata.properties[].value emits JSON array instead of stringCó thể đã có người làm @0Cymantek0 đã nhận 18 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
aboutcode-org/scancode-toolkit#5349 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Duplicate 'COPYLEFT' entries in legal file classification names in legal.py and classify.pyCó thể đã có người làm @Pradeepbeleri đã nhận 45 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
aboutcode-org/scancode-toolkit#5319 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Duplicate autogen.sh entry in commoncode default ignoresCó thể đã có người làm @Daksha1611 đã nhận 48 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
aboutcode-org/scancode-toolkit#5316 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Duplicate LGPL key in rubygems LICENSES_MAPPING makes one mapping unreachableCó thể đã có người làm @Daksha1611 đã nhận 48 ngày trước. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
aboutcode-org/scancode-toolkit#5314 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
Tất cả issue của aboutcode-org/scancode-toolkit
Issue tương tự
-
factory
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Arize-ai/phoenix#17420 · 1 bình luận · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
FireDynamics/LEDSmokeAnalysis#176 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
PC
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Make `ocifs` optionalĐang mởdependencies
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
dlt-contrib/dlt-filesystem#51 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày