You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am running Python 3.10.12 (on MacOS M1). Upon importing graphql_compiler, I get the following error:
Stacktrace
>>> from graphql_compiler import graphql_to_sql
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/__init__.py", line 3, in <module>
from .compiler import ( # noqa
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/compiler/__init__.py", line 2, in <module>
from .common import ( # noqa
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/compiler/common.py", line 4, in <module>
from . import (
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/compiler/emit_cypher.py", line 3, in <module>
from .blocks import Fold, QueryRoot, Recurse, Traverse
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/compiler/blocks.py", line 7, in <module>
from .helpers import (
File "/Users/asahai/repos/cat/.venv/lib/python3.10/site-packages/graphql_compiler/compiler/helpers.py", line 4, in <module>
from collections import Hashable, namedtuple
ImportError: cannot import name 'Hashable' from 'collections' (/opt/homebrew/Cellar/[email protected]/3.10.12_1/Frameworks/Python.framework/Versions/3.10/lib/python3.10/collections/__init__.py)
Steps to reproduce
from graphql_compiler import graphql_to_sql
How to fix
The Hashtable has been moved to collections.abc from Python 3.3 onwards, so the fix is to break up the above import into two imports as follows:
from collections import namedtuple
from collections.abc import Hashable
Version error is found
graphql-compiler 1.11.0
The text was updated successfully, but these errors were encountered:
I am running Python 3.10.12 (on MacOS M1). Upon importing graphql_compiler, I get the following error:
Stacktrace
Steps to reproduce
from graphql_compiler import graphql_to_sql
How to fix
The Hashtable has been moved to collections.abc from Python 3.3 onwards, so the fix is to break up the above import into two imports as follows:
Version error is found
graphql-compiler 1.11.0
The text was updated successfully, but these errors were encountered: