Skip to content

test_package_discovery fails on Python 3.8 #93

Closed

Description

@jaraco

In GitLab by @kapsh on Oct 12, 2019, 13:15

Run tox -e py38 -- -fv

Result:

py38 develop-inst-noop: /home/kapsh/repos/pytest_friends/importlib_metadata
py38 installed: atomicwrites==1.3.0,attrs==19.2.0,-e git+https://gitlab.com/python-devs/importlib_metadata@08a3782fc382d4d2671da66a3bc0e11695d091f1#egg=importlib_metadata,more-itertools==7.2.0,packaging==19.2,pluggy==0.13.0,py==1.8.0,pyparsing==2.4.2,pytest==5.2.1,six==1.12.0,wcwidth==0.1.7,zipp==0.6.0
py38 run-test-pre: PYTHONHASHSEED='3503751603'
py38 run-test: commands[0] | python -m unittest discover -f
..........................F
======================================================================
FAIL: test_package_discovery (importlib_metadata.tests.test_main.DiscoveryTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/kapsh/repos/pytest_friends/importlib_metadata/importlib_metadata/tests/test_main.py", line 160, in test_package_discovery
    assert all(
AssertionError

----------------------------------------------------------------------
Ran 27 tests in 0.093s

FAILED (failures=1)

It seems that isinstance(dist, Distribution) returns False for some of distributions. This test passes when running on Python 3.7.

Python 3.8.0rc1, importlib_metadata 08a3782 (latest master).

Activity

  1. added
    duplicateThis issue or pull request already exists
    on Oct 22, 2020
  2. jaraco commented on Oct 22, 2020

    @jaraco
    MemberAuthor

    In GitLab by @doko42 on Oct 19, 2019, 07:50

    also seen with the final 3.8.0 release

  3. jaraco commented on Oct 22, 2020

    @jaraco
    MemberAuthor

    In GitLab by @jaraco on Oct 26, 2019, 18:24

    Yes, I see this too. This issue is related to #91. The issue is essentially that the Distribution object exists both in stdlib and in importlib_metadata, far too reminiscent of similar errors encountered between Setuptools and distutils. I'm pretty sure that the fix for #91 will address this issue, so I'm going to close it as duplicate (even though they're coming from a different perspective and symptom).

  4. jaraco commented on Oct 22, 2020

    @jaraco
    MemberAuthor

    In GitLab by @jaraco on Oct 26, 2019, 18:24

    closed

  5. added a commit that references this issue on Dec 21, 2023
    2707fb7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions