From 70a6c727514f9c13915faf3ec00a07c591fa5c0c Mon Sep 17 00:00:00 2001 From: Kees Kluskens Date: Sat, 18 Nov 2017 22:10:39 +0100 Subject: [PATCH] Docs: fix usage of deprecated `AbstractType` A tutorial still used `graphene.AbstractType` instead of `object`, which leads to a [deprecation warning](https://github.com/graphql-python/graphene/blob/master/UPGRADE-v2.0.md#abstracttype-deprecated). --- docs/tutorial-plain.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/tutorial-plain.rst b/docs/tutorial-plain.rst index d5045aa..eca7904 100644 --- a/docs/tutorial-plain.rst +++ b/docs/tutorial-plain.rst @@ -153,7 +153,7 @@ Create ``cookbook/ingredients/schema.py`` and type the following: model = Ingredient - class Query(graphene.AbstractType): + class Query(object): all_categories = graphene.List(CategoryType) all_ingredients = graphene.List(IngredientType) @@ -426,7 +426,7 @@ We can update our schema to support that, by adding new query for ``ingredient`` model = Ingredient - class Query(graphene.AbstractType): + class Query(object): category = graphene.Field(CategoryType, id=graphene.Int(), name=graphene.String())