graphql-python / graphql-core-legacy

GraphQL base implementation for Python (legacy version – see graphql-core for the current one)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Package incompatibility with graphql-core v3

xarpy opened this issue · comments

Hello guys, I already use the graphene package with its dependencies in a commercial project, created with Flask. It's great, however I always keep an eye on the process of updating and using new resources and I thought it would be time to update the project's facilities. However, in the update process, both graphql-server-core, flask-graphql, graphql-relay, graphene packages complain about the new version of graphql-core, but some of them report that version 3.0 is recommended.
Do you mean that I should stop and use these packages?

See the returned traceback:

Collecting Flask
  Using cached Flask-1.1.1-py2.py3-none-any.whl (94 kB)
Collecting Flask-GraphQL
  Downloading Flask-GraphQL-2.0.1.tar.gz (6.1 kB)
Collecting Flask-SQLAlchemy
  Using cached Flask_SQLAlchemy-2.4.1-py2.py3-none-any.whl (17 kB)
Processing ./.cache/pip/wheels/d4/8f/d0/e3c62af58d89cbd80847eea2323da4af633993ca71f5c3ba85/Flask_JWT_Extended-3.24.1-py2.py3-none-any.whl
Collecting graphene
  Using cached graphene-2.1.8-py2.py3-none-any.whl (107 kB)
Collecting graphene-sqlalchemy
  Using cached graphene_sqlalchemy-2.2.2-py2.py3-none-any.whl (31 kB)
Collecting graphql-core
  Downloading graphql_core-3.0.3-py3-none-any.whl (181 kB)
     |████████████████████████████████| 181 kB 456 kB/s 
Collecting gunicorn
  Using cached gunicorn-20.0.4-py2.py3-none-any.whl (77 kB)
Processing ./.cache/pip/wheels/7e/5b/53/30085c62689dcfce50c8f40759945a49eb856af082e9ebf751/psycopg2-2.8.4-cp37-cp37m-linux_x86_64.whl
Collecting psycopg2-binary
  Downloading psycopg2_binary-2.8.4-cp37-cp37m-manylinux1_x86_64.whl (2.9 MB)
     |████████████████████████████████| 2.9 MB 614 kB/s 
Collecting python-dotenv
  Downloading python_dotenv-0.11.0-py2.py3-none-any.whl (17 kB)
Collecting marshmallow
  Downloading marshmallow-3.4.0-py2.py3-none-any.whl (45 kB)
     |████████████████████████████████| 45 kB 691 kB/s 
Processing ./.cache/pip/wheels/37/3d/24/5327fa50817a65ed0ee4dc8809e5c39962b0dd5e078ebf4dc1/mysqlclient-1.4.6-cp37-cp37m-linux_x86_64.whl
Collecting bcrypt
  Using cached bcrypt-3.1.7-cp34-abi3-manylinux1_x86_64.whl (56 kB)
Collecting flask-cors
  Using cached Flask_Cors-3.0.8-py2.py3-none-any.whl (14 kB)
Collecting Werkzeug>=0.15
  Downloading Werkzeug-1.0.0-py2.py3-none-any.whl (298 kB)
     |████████████████████████████████| 298 kB 358 kB/s 
Collecting itsdangerous>=0.24
  Using cached itsdangerous-1.1.0-py2.py3-none-any.whl (16 kB)
Collecting click>=5.1
  Using cached Click-7.0-py2.py3-none-any.whl (81 kB)
Collecting Jinja2>=2.10.1
  Downloading Jinja2-2.11.1-py2.py3-none-any.whl (126 kB)
     |████████████████████████████████| 126 kB 543 kB/s 
Collecting graphql-server-core<2,>=1.1
  Downloading graphql-server-core-1.2.0.tar.gz (7.0 kB)
Collecting SQLAlchemy>=0.8.0
  Downloading SQLAlchemy-1.3.13.tar.gz (6.0 MB)
     |████████████████████████████████| 6.0 MB 903 kB/s 
Collecting PyJWT>=1.6.4
  Using cached PyJWT-1.7.1-py2.py3-none-any.whl (18 kB)
Collecting six
  Using cached six-1.14.0-py2.py3-none-any.whl (10 kB)
Collecting aniso8601<=7,>=3
  Using cached aniso8601-7.0.0-py2.py3-none-any.whl (42 kB)
Collecting graphql-relay<3,>=2
  Downloading graphql_relay-2.0.1-py3-none-any.whl (20 kB)
Collecting singledispatch<4,>=3.4.0.3
  Using cached singledispatch-3.4.0.3-py2.py3-none-any.whl (12 kB)
Requirement already satisfied: setuptools>=3.0 in ./opt/miniconda3/envs/api/lib/python3.7/site-packages (from gunicorn) (45.2.0.post20200210)
Collecting cffi>=1.1
  Downloading cffi-1.14.0-cp37-cp37m-manylinux1_x86_64.whl (400 kB)
     |████████████████████████████████| 400 kB 535 kB/s 
Collecting MarkupSafe>=0.23
  Using cached MarkupSafe-1.1.1-cp37-cp37m-manylinux1_x86_64.whl (27 kB)
Collecting promise<3,>=2.3
  Downloading promise-2.3.tar.gz (19 kB)
Processing ./.cache/pip/wheels/f2/9a/90/de94f8556265ddc9d9c8b271b0f63e57b26fb1d67a45564511/pycparser-2.19-py2.py3-none-any.whl
Building wheels for collected packages: Flask-GraphQL, graphql-server-core, SQLAlchemy, promise
  Building wheel for Flask-GraphQL (setup.py) ... done
  Created wheel for Flask-GraphQL: filename=Flask_GraphQL-2.0.1-py3-none-any.whl size=6367 sha256=638da411a2dcf50b83d12e7b6c9789f40559dbfe440a0df9b0d27d72470c511d
  Stored in directory: /home/xarpy/.cache/pip/wheels/61/4d/41/da722efb9c0726c17924112def0af25a2db29ca5faa172b1d0
  Building wheel for graphql-server-core (setup.py) ... done
  Created wheel for graphql-server-core: filename=graphql_server_core-1.2.0-py2.py3-none-any.whl size=7534 sha256=873c7729f9f545537b0a6adad2a1070b71f8dee69b31b4d3dc45a29b81d1fe18
  Stored in directory: /home/xarpy/.cache/pip/wheels/2b/ce/0c/d8e3d500628c9cd3ca65d2a35d8733d22197efd2937761b946
  Building wheel for SQLAlchemy (setup.py) ... done
  Created wheel for SQLAlchemy: filename=SQLAlchemy-1.3.13-cp37-cp37m-linux_x86_64.whl size=1221973 sha256=747ee140c686362966d1bea034f3e506badb4ed6b09ee8d19879ecce389358a5
  Stored in directory: /home/xarpy/.cache/pip/wheels/b9/ba/77/163f10f14bd489351530603e750c195b0ceceed2f3be2b32f1
  Building wheel for promise (setup.py) ... done
  Created wheel for promise: filename=promise-2.3-py3-none-any.whl size=21495 sha256=1a0f6bc578724389cd300d07316ea9c4e711dfbcc52756ebadb92237480b6bd8
  Stored in directory: /home/xarpy/.cache/pip/wheels/29/93/c6/762e359f8cb6a5b69c72235d798804cae523bbe41c2aa8333d
Successfully built Flask-GraphQL graphql-server-core SQLAlchemy promise
ERROR: graphql-server-core 1.2.0 has requirement graphql-core<3,>=2.3, but you'll have graphql-core 3.0.3 which is incompatible.
ERROR: flask-graphql 2.0.1 has requirement graphql-core<3,>=2.1, but you'll have graphql-core 3.0.3 which is incompatible.
ERROR: graphql-relay 2.0.1 has requirement graphql-core<3,>=2.2, but you'll have graphql-core 3.0.3 which is incompatible.
ERROR: graphene 2.1.8 has requirement graphql-core<3,>=2.1, but you'll have graphql-core 3.0.3 which is incompatible.
Installing collected packages: Werkzeug, itsdangerous, click, MarkupSafe, Jinja2, Flask, graphql-core, six, promise, graphql-server-core, Flask-GraphQL, SQLAlchemy, Flask-SQLAlchemy, PyJWT, Flask-JWT-Extended, aniso8601, graphql-relay, graphene, singledispatch, graphene-sqlalchemy, gunicorn, psycopg2, psycopg2-binary, python-dotenv, marshmallow, mysqlclient, pycparser, cffi, bcrypt, flask-cors
Successfully installed Flask-1.1.1 Flask-GraphQL-2.0.1 Flask-JWT-Extended-3.24.1 Flask-SQLAlchemy-2.4.1 Jinja2-2.11.1 MarkupSafe-1.1.1 PyJWT-1.7.1 SQLAlchemy-1.3.13 Werkzeug-1.0.0 aniso8601-7.0.0 bcrypt-3.1.7 cffi-1.14.0 click-7.0 flask-cors-3.0.8 graphene-2.1.8 graphene-sqlalchemy-2.2.2 graphql-core-3.0.3 graphql-relay-2.0.1 graphql-server-core-1.2.0 gunicorn-20.0.4 itsdangerous-1.1.0 marshmallow-3.4.0 mysqlclient-1.4.6 promise-2.3 psycopg2-2.8.4 psycopg2-binary-2.8.4 pycparser-2.19 python-dotenv-0.11.0 singledispatch-3.4.0.3 six-1.14.0

It seems you have installed several tools that require GraphQL-core 2 (the legacy version), so you cannot upgrade to GraphQL-core 3. If you want to upgrade, you must check if there are already newer versions of your tools that are compatible with GraphQL-core 3 and use these instead. E.g. Graphene 3 is based on GraphQL-core v3, Graphene 2 is based on GraphQL-core v2. For some of the tools, there may be no newer versions yet, but we are working on that.

Thanks @Cito, when the project started we didn't have a third version yet. We believed that the packages would follow the versioning standard, so we didn't find incompatibility.
Now we really have to wait and in whatever way the team can improve the project to move forward together.

Where do you think packages do not follow a versioning standard? Some tools did not have proper version limits for a while, but I think that has be solved already. E.g. graphql-server-core 1.2.0 has the proper requirements "graphql-core<3,>=2.3" as you see in your error message.

It's just that you can't use graphql-core 3 when you are still using older tools requiring graphql-core 2, just like you could not use Python 3 when you were using libraries that did not yet support Python 3. Unfortunately, It takes a while until all tools in the ecosystem are available in newer versions.

What would help most if people volunteer as responsible maintainers or caretakers for one or two of the sub-projects in the ecosystem which are currently not moving forward. It's difficult to find such people, since it's always easier and more fun to start new projects than maintaining old projects in the long run (particularly if they are not your own old projects but those of other people) and keeping them in line with the rest of the ecosystem.

Sorry that it felt like I was just taking advantage of the work you did. I am aware of the sacrifice for maintenance and all the effort of the team, whenever we have a passion for something it is crucial to keep improving. So, in whatever I can help, I am willing to collaborate with the projects.
So, as I said before, thank you very much for the contribution @Cito and the rest of the team and again sorry if I have written or said something in a crude way.

No, don't worry, all is well, I just wanted to describe the current situation. Every feedback and help is appretiated.