diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 2e220b9..fa4b968 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -17,7 +17,7 @@ are used for versioning (schema follows below):
0.6.6
-----
-2020-12-25
+2020-12-26
.. note::
diff --git a/docs/debugging.rst b/docs/debugging.rst
index 63b6776..b50c37d 100644
--- a/docs/debugging.rst
+++ b/docs/debugging.rst
@@ -1,5 +1,7 @@
Debugging
=========
+Logging queries to console
+--------------------------
The ``LOGGING_LEVEL`` key represents the logging level (defaults to
``logging.ERROR``). Override if needed.
diff --git a/docs/index.rst b/docs/index.rst
index 1c2b1f7..e882dfc 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -35,7 +35,7 @@ integration for `Graphene `__.
Prerequisites
=============
- Graphene 2.x. *Support for Graphene 1.x is not intended.*
-- Python 3.6, 3.7, 3.8, 3.9. *Support for Python 2 is not intended.*
+- Python 3.6, 3.7, 3.8, 3.9 and 3.10. *Support for Python 2 is not intended.*
- Elasticsearch 6.x, 7.x. *Support for Elasticsearch 5.x is not intended.*
Main features and highlights
diff --git a/examples/apps/django_app/inject.py b/examples/apps/django_app/inject.py
index f3f87e7..7a380a1 100644
--- a/examples/apps/django_app/inject.py
+++ b/examples/apps/django_app/inject.py
@@ -15,4 +15,7 @@ def project_dir(base):
sys.path.insert(0, project_dir("../../../src"))
sys.path.insert(0, project_dir("../../../examples"))
-sys.path.insert(0, '/home/delusionalinsanity/bbrepos/graphene-elastic/examples')
+sys.path.insert(
+ 0,
+ '/home/delusionalinsanity/bbrepos/graphene-elastic/examples'
+)
diff --git a/examples/apps/django_app/run.py b/examples/apps/django_app/run.py
index c9583cf..08aec79 100644
--- a/examples/apps/django_app/run.py
+++ b/examples/apps/django_app/run.py
@@ -36,8 +36,8 @@
configure(locals(), django_admin=True)
-from graphene_django.views import GraphQLView
-from graphene_elastic.settings import graphene_settings
+from graphene_django.views import GraphQLView # NOQA
+from graphene_elastic.settings import graphene_settings # NOQA
route(
'graphql',
GraphQLView.as_view(
diff --git a/examples/apps/graphql_views.py b/examples/apps/graphql_views.py
deleted file mode 100644
index 16f402e..0000000
--- a/examples/apps/graphql_views.py
+++ /dev/null
@@ -1,24 +0,0 @@
-from graphene.test import Client
-
-from graphql_schema.schema import schema
-
-
-def posts():
- client = Client(schema)
- query = '''
- query {
- posts {
- title
- category
- comments {
- author
- }
- }
- }
- '''
- executed = client.execute(query)
- assert executed == {
- 'data': {
- 'hey': 'hello!'
- }
- }
diff --git a/examples/apps/middleware.py b/examples/apps/middleware.py
index 5e4ff92..ac17dcf 100644
--- a/examples/apps/middleware.py
+++ b/examples/apps/middleware.py
@@ -10,7 +10,9 @@ def timing_middleware(next, root, info, **args):
start = timer()
return_value = next(root, info, **args)
duration = round((timer() - start) * 1000, 2)
- parent_type_name = root._meta.name if root and hasattr(root, '_meta') else ''
+ parent_type_name = root._meta.name \
+ if root and hasattr(root, '_meta') \
+ else ''
logger.debug("timing_middleware")
logger.debug(f"{parent_type_name}.{info.field_name}: {duration} ms")
return return_value
diff --git a/examples/factories/generate.py b/examples/factories/generate.py
index 6726ace..c8dccae 100644
--- a/examples/factories/generate.py
+++ b/examples/factories/generate.py
@@ -14,9 +14,9 @@ def project_dir(base):
sys.path.insert(0, project_dir("../../examples"))
-from factories.blog_post import PostFactory
-from factories.site_user import UserFactory
-from factories.farm_animal import AnimalFactory
+from factories.blog_post import PostFactory # NOQA
+from factories.site_user import UserFactory # NOQA
+from factories.farm_animal import AnimalFactory # NOQA
def generate(num_items=100):
diff --git a/examples/search_index/documents/animal.py b/examples/search_index/documents/animal.py
index c8fef4b..abaa41f 100644
--- a/examples/search_index/documents/animal.py
+++ b/examples/search_index/documents/animal.py
@@ -30,13 +30,15 @@
connections.create_connection(**ELASTICSEARCH_CONNECTION)
-html_strip = analyzer('html_strip',
+html_strip = analyzer(
+ 'html_strip',
tokenizer="standard",
filter=["lowercase", "stop", "snowball"],
char_filter=["html_strip"]
)
-html_strip_preserve_case = analyzer('html_strip',
+html_strip_preserve_case = analyzer(
+ 'html_strip',
tokenizer="standard",
filter=["stop", "snowball"],
char_filter=["html_strip"]
diff --git a/examples/search_index/documents/post.py b/examples/search_index/documents/post.py
index ec31e12..9e4e36c 100644
--- a/examples/search_index/documents/post.py
+++ b/examples/search_index/documents/post.py
@@ -30,7 +30,8 @@
connections.create_connection(**ELASTICSEARCH_CONNECTION)
-html_strip = analyzer('html_strip',
+html_strip = analyzer(
+ 'html_strip',
tokenizer="standard",
filter=["lowercase", "stop", "snowball"],
char_filter=["html_strip"]
diff --git a/examples/search_index/documents/user.py b/examples/search_index/documents/user.py
index 8c36c91..307877d 100644
--- a/examples/search_index/documents/user.py
+++ b/examples/search_index/documents/user.py
@@ -26,7 +26,8 @@
connections.create_connection(**ELASTICSEARCH_CONNECTION)
-html_strip = analyzer('html_strip',
+html_strip = analyzer(
+ 'html_strip',
tokenizer="standard",
filter=["lowercase", "stop", "snowball"],
char_filter=["html_strip"]
diff --git a/scripts/pycodestyle.sh b/scripts/pycodestyle.sh
index 2175dc1..5d5be84 100755
--- a/scripts/pycodestyle.sh
+++ b/scripts/pycodestyle.sh
@@ -1,3 +1,4 @@
#!/usr/bin/env bash
reset
pycodestyle src/graphene_elastic/
+pycodestyle examples/ --exclude examples/apps/django_app/local_overrides.py,examples/apps/flask_app/local_overrides.py
diff --git a/setup.py b/setup.py
index 09ceaa8..206d385 100644
--- a/setup.py
+++ b/setup.py
@@ -2,7 +2,7 @@
setup(
name="graphene-elastic",
- version="0.6.5",
+ version="0.6.6",
description="Graphene Elasticsearch (DSL) integration",
long_description=open("README.rst").read(),
url="https://github.com/barseghyanartur/graphene-elastic",
@@ -24,6 +24,8 @@
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
+ "Programming Language :: Python :: 3.9",
+ "Programming Language :: Python :: 3.10",
],
keywords="api graphql protocol rest relay graphene elasticsearch "
"elasticsearch-dsl",
diff --git a/src/graphene_elastic/__init__.py b/src/graphene_elastic/__init__.py
index 182266b..5fafef4 100644
--- a/src/graphene_elastic/__init__.py
+++ b/src/graphene_elastic/__init__.py
@@ -2,7 +2,7 @@
from .types import ElasticsearchObjectType
__title__ = 'graphene-elastic'
-__version__ = '0.6.5'
+__version__ = '0.6.6'
__author__ = 'Artur Barseghyan '
__copyright__ = '2019-2020 Artur Barseghyan'
__license__ = 'GPL-2.0-only OR LGPL-2.1-or-later'