Skip to content
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

Undeclared typing-extensions dependency in 6.5.0 #323

Closed
pstjohn opened this issue Jan 3, 2025 · 3 comments · Fixed by #324
Closed

Undeclared typing-extensions dependency in 6.5.0 #323

pstjohn opened this issue Jan 3, 2025 · 3 comments · Fixed by #324

Comments

@pstjohn
Copy link
Contributor

pstjohn commented Jan 3, 2025

This import from typing_extensions is causing a ModuleNotFound error for me. I think you'll need to add typing-extensions as a dependency in pyproject.toml

from typing_extensions import Literal

@mhogan-nwra
Copy link

mhogan-nwra commented Jan 3, 2025

I am also encountering this error. This is my stack

env_TEST_3.9/lib/python3.9/site-packages/matplotlib/pyplot.py:58: in <module> 
    from matplotlib import (  # noqa: F401 Re-exported for typing.
env_TEST_3.9/lib/python3.9/site-packages/matplotlib/style/__init__.py:1: in <module>
    from .core import available, context, library, reload_library, use
env_TEST_3.9/lib/python3.9/site-packages/matplotlib/style/core.py:26: in <module>
    import importlib_resources
env_TEST_3.9/lib/python3.9/site-packages/importlib_resources/__init__.py:10: in <module>
    from ._common import (
env_TEST_3.9/lib/python3.9/site-packages/importlib_resources/_common.py:13: in <module>
    from .abc import ResourceReader, Traversable
env_TEST_3.9/lib/python3.9/site-packages/importlib_resources/abc.py:20: in <module>
    from typing_extensions import Literal
E   ModuleNotFoundError: No module named 'typing_extensions'

EDIT: I experience this issue in a 3.9 virtualenv in my CI pipeline, but I do not encounter this problem with CI virtualenv's with 3.10+.

@jaraco
Copy link
Member

jaraco commented Jan 3, 2025

Well, shoot. This dependency also will cause problems when porting the change to CPython, as CPython cannot have dependencies. I wonder what the pure-python equivalent would be.

@jaraco
Copy link
Member

jaraco commented Jan 3, 2025

6.5.2 being released now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants