1
- # GraphQL-core-next
1
+ # GraphQL-core 3
2
2
3
- GraphQL-core-next is a Python 3.6+ port of [ GraphQL.js] ( https://github.com/graphql/graphql-js ) ,
3
+ GraphQL-core 3 is a Python 3.6+ port of [ GraphQL.js] ( https://github.com/graphql/graphql-js ) ,
4
4
the JavaScript reference implementation for [ GraphQL] ( https://graphql.org/ ) ,
5
5
a query language for APIs created by Facebook.
6
6
@@ -12,31 +12,22 @@ a query language for APIs created by Facebook.
12
12
[ ![ Python 3 Status] ( https://pyup.io/repos/github/graphql-python/graphql-core-next/python-3-shield.svg )] ( https://pyup.io/repos/github/graphql-python/graphql-core-next/ )
13
13
[ ![ Code Style] ( https://img.shields.io/badge/code%20style-black-000000.svg )] ( https://github.com/ambv/black )
14
14
15
- The current version 3.0.0a0 of GraphQL-core-next is up-to-date with GraphQL.js version
16
- 14.4.0. All parts of the API are covered by an extensive test suite of currently 1882
17
- unit tests.
15
+ The current version 3.0.0a0 of GraphQL-core is up-to-date
16
+ with GraphQL.js version 14.4.0.
18
17
19
- Development will be continued with the new distribution name GraphQL-core from now on.
20
-
21
-
22
- ## GraphQL-core-next is now GraphQL-core 3
23
-
24
- GraphQL-core-next has been discontinued as a separate Python distribution.
25
- Instead, it is now released as GraphQL-core version 3 and newer, replacing
26
- the existing GraphQL-core distribution. The old versions of GraphQL-core,
27
- which also support older Python versions, are still available.
18
+ All parts of the API are covered by an extensive test suite
19
+ of currently 1882 unit tests.
28
20
29
21
30
22
## Documentation
31
23
32
- A more detailed documentation for GraphQL-core-next can be found at
24
+ A more detailed documentation for GraphQL-core 3 can be found at
33
25
[ graphql-core-next.readthedocs.io] ( https://graphql-core-next.readthedocs.io/ ) .
34
26
35
27
The documentation for GraphQL.js can be found at [ graphql.org/graphql-js/] ( https://graphql.org/graphql-js/ ) .
36
28
37
29
The documentation for GraphQL itself can be found at [ graphql.org] ( https://graphql.org/ ) .
38
30
39
-
40
31
There will be also [ blog articles] ( https://cito.github.io/tags/graphql/ ) with more usage
41
32
examples.
42
33
@@ -53,19 +44,19 @@ README and the corresponding tests in parallel.
53
44
54
45
## Installation
55
46
56
- GraphQL-core-next can be installed from PyPI using the built-in pip command:
47
+ GraphQL-core 3 can be installed from PyPI using the built-in pip command:
57
48
58
- python -m pip install graphql-core-next
49
+ python -m pip install " graphql-core>=3"
59
50
60
51
Alternatively, you can also use [ pipenv] ( https://docs.pipenv.org/ ) for installation in a
61
52
virtual environment:
62
53
63
- pipenv install graphql-core-next
54
+ pipenv install " graphql-core>=3"
64
55
65
56
66
57
## Usage
67
58
68
- GraphQL-core-next provides two important capabilities: building a type schema, and
59
+ GraphQL-core provides two important capabilities: building a type schema, and
69
60
serving queries against that type schema.
70
61
71
62
First, build a GraphQL type schema which maps to your code base:
@@ -176,25 +167,25 @@ finally:
176
167
177
168
## Goals and restrictions
178
169
179
- GraphQL-core-next tries to reproduce the code of the reference implementation GraphQL.js
170
+ GraphQL-core tries to reproduce the code of the reference implementation GraphQL.js
180
171
in Python as closely as possible and to stay up-to-date with the latest development of
181
172
GraphQL.js.
182
173
183
- It has been created as a modern alternative to
184
- [ GraphQL-core] ( https://github.com/graphql-python/graphql-core ) , a prior work
185
- by Syrus Akbary, based on an older version of GraphQL.js and also targeting
186
- older Python versions. Some parts of GraphQL-core-next have been inspired by
187
- GraphQL-core or directly taken over with only slight modifications, but most of the code
188
- has been re-implemented from scratch, replicating the latest code in GraphQL.js very
189
- closely and adding type hints for Python.
174
+ GraphQL-core 3 (formerly known as GraphQL-core-next) has been created as a modern
175
+ alternative to [ GraphQL-core 2 ] ( https://github.com/graphql-python/graphql-core ) ,
176
+ a prior work by Syrus Akbary, based on an older version of GraphQL.js and also
177
+ targeting older Python versions. Some parts of GraphQL-core 3 have been inspired by
178
+ GraphQL-core 2 or directly taken over with only slight modifications, but most of the
179
+ code has been re-implemented from scratch, replicating the latest code in GraphQL.js
180
+ very closely and adding type hints for Python.
190
181
191
- Design goals for the GraphQL-core-next library are:
182
+ Design goals for the GraphQL-core 3 library are:
192
183
193
184
* to be a simple, cruft-free, state-of-the-art implementation of GraphQL using current
194
185
library and language versions
195
186
* to be very close to the GraphQL.js reference implementation, while still using a
196
187
Pythonic API and code style
197
- * to make extensive use of Python type hints, similar to how GraphQL.js makes use of Flow
188
+ * to make extensive use of Python type hints, similar to how GraphQL.js makes uses Flow
198
189
* to use [ black] ( https://github.com/ambv/black ) for automatic code formatting
199
190
* to replicate the complete Mocha-based test suite of GraphQL.js using
200
191
[ pytest] ( https://docs.pytest.org/ )
@@ -216,10 +207,9 @@ Some restrictions (mostly in line with the design goals):
216
207
also been created by Syrus Akbary, who meanwhile has handed over the maintenance
217
208
and future development to members of the GraphQL-Python community.
218
209
219
- The current version 2 of Graphene is using Graphql-core as core library for much of
220
- the heavy lifting. Note that Graphene 2 is not compatible with GraphQL-core-next.
221
- The new version 3 of Graphene however is planned to use GraphQL-core-next instead of
222
- GraphQL-core, and GraphQL-core-next will be renamed to Graphql-core 3.
210
+ The current version 2 of Graphene is using Graphql-core 2 as core library for much of
211
+ the heavy lifting. Note that Graphene 2 is not compatible with GraphQL-core 3.
212
+ The new version 3 of Graphene will use GraphQL-core 3 instead of GraphQL-core 2.
223
213
224
214
* [ Ariadne] ( https://github.com/mirumee/ariadne ) is a Python library for implementing
225
215
GraphQL servers using schema-first approach created by Mirumee Software.
@@ -239,9 +229,9 @@ Changes are tracked as
239
229
240
230
## Credits and history
241
231
242
- The GraphQL-core-next library
232
+ The GraphQL-core 3 library
243
233
* has been created and is maintained by Christoph Zwerschke
244
- * uses ideas and code from GraphQL-core, a prior work by Syrus Akbary
234
+ * uses ideas and code from GraphQL-core 2 , a prior work by Syrus Akbary
245
235
* is a Python port of GraphQL.js which has been developed by Lee Byron and others
246
236
at Facebook, Inc. and is now maintained
247
237
by the [ GraphQL foundation] ( https://gql.foundation/join/ )
@@ -255,6 +245,6 @@ and ported to many different programming languages.
255
245
256
246
## License
257
247
258
- GraphQL-core-next is
248
+ GraphQL-core 3 is
259
249
[ MIT-licensed] ( https://github.com/graphql-python/graphql-core-next/blob/master/LICENSE ) ,
260
250
just like GraphQL.js.
0 commit comments