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

ModuleNotFoundError: No module named 'typing_extensions' #5107

Closed
leszekhanusz opened this issue Oct 24, 2020 · 7 comments · Fixed by #5123 or #5374
Closed

ModuleNotFoundError: No module named 'typing_extensions' #5107

leszekhanusz opened this issue Oct 24, 2020 · 7 comments · Fixed by #5123 or #5374
Labels

Comments

@leszekhanusz
Copy link

🐞 Describe the bug

After updating aiohttp from 3.6.2 to 3.7.0, the gql tests are failing on python 3.8 with the Exception ModuleNotFoundError: No module named 'typing_extensions'

tests/conftest.py:15: in <module>
    from aiohttp.test_utils import TestServer as AIOHTTPTestServer
.tox/py38/lib/python3.8/site-packages/aiohttp/test_utils.py:43: in <module>
    from .web import (
.tox/py38/lib/python3.8/site-packages/aiohttp/web.py:23: in <module>
    from .web_app import Application as Application
.tox/py38/lib/python3.8/site-packages/aiohttp/web_app.py:39: in <module>
    from .web_middlewares import _fix_request_current_app
.tox/py38/lib/python3.8/site-packages/aiohttp/web_middlewares.py:7: in <module>
    from .web_urldispatcher import SystemRoute
.tox/py38/lib/python3.8/site-packages/aiohttp/web_urldispatcher.py:36: in <module>
    from typing_extensions import TypedDict
E   ModuleNotFoundError: No module named 'typing_extensions'

💡 To Reproduce

Check the PR #156

@leszekhanusz
Copy link
Author

Probably related to the aiohttp PR #5078 (6 days ago)

@asvetlov
Copy link
Member

Thanks for the report!

@asvetlov
Copy link
Member

Fixed by #5123

@chaos-settings
Copy link

Hi, I'm still running into a similar issue with aiohttp v3.7.3.

I have a Docker image using Python 3.8 in which pipenv installs from a Pipfile.lock. In my Pipfile, I require python=3.8, but when I build the Pipfile.lock, the dependency typing-extensions has the marker:

"markers": "python_version < '3.8'",
"version": "==3.7.4.3"

Because of this, my pytests failed to find typing-extensions with the same error as the title of this issue.

I was able to get around this issue by explicitly requiring typing-extensions in my Pipfile, instead of implicitly installing it as a dependency of aiohttp, but it seems hacky.

@telemmaite
Copy link

Same issue as above with aiohttp==3.7.3

  File ".pyenv/versions/ENV-3.8.6/lib/python3.8/site-packages/aiohttp/http_parser.py", line 15, in <module>
    from .helpers import NO_EXTENSIONS, BaseTimerContext
  File ".pyenv/versions/ENV-3.8.6/lib/python3.8/site-packages/aiohttp/helpers.py", line 48, in <module>
    from typing_extensions import Protocol
ModuleNotFoundError: No module named 'typing_extensions'

@nomad-software

This comment has been minimized.

@webknjaz
Copy link
Member

Same issue as above with aiohttp==3.7.3

It can't be the same: e7dc844 + python/typing@c6c7dfd.

@aio-libs aio-libs locked as resolved and limited conversation to collaborators Jan 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
6 participants