Skip to content

Breaking change in graphql-core #51

Closed
@NathanDeMaria

Description

@NathanDeMaria

There's some backward-compatibility breaks in graphql-core==3.0.0, that lead to the following import error:

from gql import Client
ImportError                               Traceback (most recent call last)
<ipython-input-1-2d34726b19bf> in <module>
----> 1 from gql import Client

~\AppData\Local\Continuum\miniconda3\lib\site-packages\gql\__init__.py in <module>
      1 from .gql import gql
----> 2 from .client import Client
      3
      4 __all__ = ['gql', 'Client']

~\AppData\Local\Continuum\miniconda3\lib\site-packages\gql\client.py in <module>
      1 import logging
      2
----> 3 from graphql import parse, introspection_query, build_ast_schema, build_client_schema
      4 from graphql.validation import validate
      5

ImportError: cannot import name 'introspection_query' from 'graphql' (C:\Users\nathan.demaria\AppData\Local\Continuum\miniconda3\lib\site-packages\graphql\__init__.py)

AFAIK the solution here is add a ceiling graphql-core<3.0.0 to the install_requires of this package, but I'm curious if somebody familiar with the plan for packages in this repo has better options/longer term recommendations - I see repos for graphql-core-next and gql-next, and it looks like the graphql-core package is now published to PyPI from the -next repo, but gql is still from this repo.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions