Closed Younes-Piro closed 2 years ago
@Younes-Piro you mention that you are using python = "3.6"
but the actual import error shows that python 3.10 is used.
If you can update graphene to the latest version which supports 3.10 it should be fine.
@theodesp mentioned the correct solution. The problem originates from collections.abc
changes.
Traceback (most recent call last): File "C:\Users\asus\OneDrive\Desktop\flask\first_app\app.py", line 9, in
from schema import schema
File "C:\Users\asus\OneDrive\Desktop\flask\first_app\schema.py", line 1, in
import graphene
File "C:\Users\asus\OneDrive\Desktop\flask\first_app\env\lib\site-packages\graphene__init__.py", line 3, in
from .types import (
File "C:\Users\asus\OneDrive\Desktop\flask\first_app\env\lib\site-packages\graphene\types__init.py", line 4, in
from .objecttype import ObjectType
File "C:\Users\asus\OneDrive\Desktop\flask\first_app\env\lib\site-packages\graphene\types\objecttype.py", line 4, in
from .field import Field
File "C:\Users\asus\OneDrive\Desktop\flask\first_app\env\lib\site-packages\graphene\types\field.py", line 2, in
from collections import Mapping, OrderedDict
ImportError: cannot import name 'Mapping' from 'collections' (C:\Program Files\Python310\lib\collections\ init__.py)
python = "3.6" Flask = "1.1.1" pymongo = "3.10.1" dnspython = "^2.2.0" python-dotenv = "^0.19.2" Flask-GraphQL = "2.0.1" graphene = "2.1.8" mongoengine = "^0.24.0" graphene-mongo = "0.2.8" graphql-relay = "2.0.1" graphql-server-core = "1.2.0" graphql-core = "2.3.2"