Skip to content

Commit

Permalink
Merge pull request #171 from evo-company/update-08-docs
Browse files Browse the repository at this point in the history
update 0.8.x docs
  • Loading branch information
kindermax authored Sep 19, 2024
2 parents 0ea5d9e + 418b768 commit 59b0f87
Showing 1 changed file with 20 additions and 21 deletions.
41 changes: 20 additions & 21 deletions docs/changelog/changes_08.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,27 @@ Changes in 0.8
0.8.0rcX
~~~~~~~~

- Introduce `Schema`. This is a new high-level api with aim to provide single entrypoint for validation/execution
- Introduce ``Schema`` . This is a new high-level api with aim to provide single entrypoint for validation/execution
and query/mutations. Previously we had to manage two serapate graphs - one for Query other for Mutation or use `endpoint`
api but `endpoint` api is more like an integration-like api for http handlers.
- `Endpoint` now is much simpler under the hood and it basically delegates execution to schema, only providing support for batching.
- Drop custom `validate` function for federation since we now have better support for `_entities` and `_service` fields and their corresponding types.
- Add new `M` query builder that indicates that this is a `mutation`. It must be used to build a `mutation` query that will be passed to
`Schema.execute` method which will then infer that this is a mutation query Node.
- Drop `hiku.federation.validate.validate`
- Drop `hiku.federation.denormalize`
- Drop `hiku.federation.engine`
- Drop `hiku.federation.endpoint` - use `hiku.endpoint` instead
- Merge `tests.test_federation.test_endpoint` and `tests.test_federation.test_engine` into `tests.test_federation.test_schema`
- Change `QueryDepthValidator` hook to `on_validate`
- Change `GraphQLResponse` type - it now has both `data` and `errors` fields
- Rename `on_dispatch` hook to `on_operation`
- Remove old `on_operation` hook
- Remove `execute` method from `BaseGraphQLEndpoint` class
- Add `process_result` method to `BaseGraphQLEndpoint` class
- Move `GraphQLError` to `hiku.error` module
- Drop `GraphQLError.errors` field. Earlier we used to store multiple errors in single `GraphQLError` but now its one message - one `GraphQLError`.
- Add `GraphQLError.message` field
- Dropped support for Python 3.7, which ended support on 2023-06-27
api but ``endpoint`` api is more like an integration-like api for http handlers.
- ``Schema`` returns ``ExecutionResult`` dataclass with ``data``, ``errors`` and ``result`` fields. ``data`` already denormalized but access to `Proxy` object at ``result`` field is retained.
- ``Endpoint`` now is much simpler under the hood and it basically delegates execution to schema, only providing support for batching.
- Drop custom ``validate`` function for federation since we now have better support for ```_entities`` and ```_service`` fields and their corresponding types.
- Add new ``M`` query builder that indicates that this is a ``mutation``. It must be used to build a ``mutation`` query that will be passed to
``Schema.execute``` method which will then infer that this is a mutation query Node.
- Drop ``hiku.federation.validate.validate``
- Drop ``hiku.federation.denormalize``
- Drop ``hiku.federation.engine``
- Drop ``hiku.federation.endpoint`` - use ``hiku.endpoint`` instead
- Change ``QueryDepthValidator`` hook to ``on_validate``
- Change ``GraphQLResponse`` type used by endpoint - it now has both ``data`` and ``errors`` fields
- Rename ``on_dispatch`` hook to ``on_operation``
- Remove ``execute`` method from ``BaseGraphQLEndpoint`` class
- Add ``process_result`` method to ``BaseGraphQLEndpoint`` class - it returns ``GraphQLResponse`` object with ``{"data": ...}`` or ``{"data": null, "errors": [...]`` is case ther are errors.
- Move ``GraphQLError`` to ``hiku.error`` module
- Drop ``GraphQLError.errors`` field. Earlier we used to store multiple errors in single ``GraphQLError`` but now its one message - one ``GraphQLError``.
- Add ``GraphQLError.message`` field
- Dropped support for ``Python 3.7``, which ended support on 2023-06-27

Backward-incompatible changes
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down

0 comments on commit 59b0f87

Please sign in to comment.