Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[BUG] Using attr for version specification with namespace packages #2919

Open
@hsorby

Description

@hsorby

setuptools version

setuptools == 58.5.3

Python version

Python 3.9

OS

macOS

Additional environment information

No response

Description

When I try topip install <namespace-package> usingattr to determine the value of version I get a failure message.

Expected behavior

Thepip install <namespace-package> command works successfully.

How to Reproduce

I have created an example to show this behaviour:

  1. Clone repo.https://github.com/hsorby/setuptools-issue
  2. Create virtual environment:python -m venv issue
  3. Activate:source issue/bin/activate
  4. cd setuptools-issue
  5. Installanimals.cat package:pip install animals.cat/
  6. Installanimals.dog package:pip install animals.dog/

This will fail becauseModuleNotFoundError: No module named 'animals.dog'

If I now uninstallanimals.cat:pip uninstall animals.cat and then repeat steps 5. and 6. they will succeed, I'm guessing because something has been leftover from the uninstall?

Output

    File "<frozen importlib._bootstrap>", line 1030, in _gcd_import    File "<frozen importlib._bootstrap>", line 1007, in _find_and_load    File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked  ModuleNotFoundError: No module named 'animals.dog'  ----------------------------------------

Code of Conduct

  • I agree to follow the PSF Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp