-
-
Notifications
You must be signed in to change notification settings - Fork 30.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[3.10] Package names with different metadata types aren't deduplicated #99130
Comments
According to the compatibility matrix, Python 3.10 was synced at importlib_metadata 4.4. I'll confirm that's the case and then plan to backport the fix to importlib_metadata 4.4.x. |
I can see in GH-31854, Python 3.10 got synced with importlib_metadata 4.11.3, so that should make the fix easier. |
It's not that simple. Some bugfixes were backported, but other changes from importlib_metadata 4.5-4.11 were not, so there's no place on the importlib_metadata cpython branch that corresponds to what's in CPython 3.10. This complicated scenario is a consequence of CPython's branching strategy, which only allows for squash merges (so it's not possible to merge importlib_metadata into cpython) and only allows for manual backports (no relation between the history in version branches and main). |
It looks like python/importlib_metadata@ba30e9b corresponds most closely to where CPython 3.10 was synced. To that commit I've applied the other bugfixes as found in CPython 3.10.8 as python/importlib_metadata@996308821b. Against that commit, I'm applying the changes from the merge requests that comprised 4.11.4:
|
Drat. Looks like the second cherry-pick is dependent on python/importlib_metadata@1e19fd2. |
Thanks for finding this, @jaraco. I merged it. |
In python/importlib_metadata#377, Benoit reports that the "_normalized_name" of importlib_metadata and importlib.metadata is including an extraneous
.egg
. This issue means that in environments where both.dist-info
and.egg-info
exist for a package, they're not deduplicated and the entry points are returned for both. The scenario is common and problemmatic as evidenced by other bug reports (python/importlib_metadata#410, python/importlib_metadata#413). The fix, added in importlib_metadata 4.11.4, has been ported to Python 3.11.1 in #98875, but the fix should also be backported to Python 3.10.The text was updated successfully, but these errors were encountered: