Remove pluggy usage; replace the pluggy < 1.7.0 cap with direct entry-point loading
メンテナーはふだん 3 日以内に返信
まだ誰も着手していません。
- #5373 @knowprasad による — マージされずにクローズ
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 72/100
- issue の種類
- リファクタリング
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- python
調査の方向性
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.
索引モデルが issue の本文から書いたものです。
説明
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.
- 主要言語
- Python
- スター
- 2.7k
- フォーク
- 831
- 平均マージ
- 3日 4時間
- マージ済み PR(30日)
- 7
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
aboutcode-org/scancode-toolkit のほかの issue
-
bug: Unreachable JSON extension and format validation in validate_input_path対応中かも @0Cymantek0 が 17 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
aboutcode-org/scancode-toolkit#5351 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
CycloneDX output: metadata.properties[].value emits JSON array instead of string対応中かも @0Cymantek0 が 17 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
aboutcode-org/scancode-toolkit#5349 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
Duplicate 'COPYLEFT' entries in legal file classification names in legal.py and classify.py対応中かも @Pradeepbeleri が 45 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
aboutcode-org/scancode-toolkit#5319 · コメント 2 件 ·
メンテナーはふだん 3 日以内に返信
-
Duplicate autogen.sh entry in commoncode default ignores対応中かも @Daksha1611 が 47 日前に担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
aboutcode-org/scancode-toolkit#5316 ·
メンテナーはふだん 3 日以内に返信
-
Duplicate LGPL key in rubygems LICENSES_MAPPING makes one mapping unreachable対応中かも @Daksha1611 が 47 日前に担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
aboutcode-org/scancode-toolkit#5314 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
aboutcode-org/scancode-toolkit の issue をすべて見る
似ている issue
-
app: scripts status: backlog type: documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
netbox-community/netbox-scripts#68 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 91/100
marin-community/marin#10765 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 70/100
flathub/com.unity.UnityHub#230 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
namespace operations
難易度 1/5 1時間未満 初心者へのやさしさ 63/100
EclipseFdn/open-vsx.org#14910 ·
メンテナーはふだん 1 日以内に返信