diff --git a/Dockerfile b/Dockerfile index 5368f21..2f0be4b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,7 +8,7 @@ ENV PDM_USE_VENV=no ENV PYTHONPATH=/work/__pypackages__/3.7/lib RUN apt-get update && apt-get install -y libpq-dev && \ - pip install --upgrade pip==${PIP_VERSION} && pip install pdm==${PDM_VERSION} + pip install --upgrade pip==${PIP_VERSION} && pip install pdm==${PDM_VERSION} # for pyproject.toml to extract version COPY hiku/__init__.py ./hiku/__init__.py @@ -26,7 +26,7 @@ RUN pdm sync -G dev FROM base as docs -RUN pdm sync -G docs +RUN pdm sync -G dev -G docs FROM base as tests diff --git a/README.rst b/README.rst index a2bd623..2ef3039 100644 --- a/README.rst +++ b/README.rst @@ -38,7 +38,7 @@ Highlights ~~~~~~~~~~ * Not coupled to a single specific query language -* Flexibility in result serialization, including binary formats +* Flexibility in result serialization * Natively uses normalized result representation, without data duplication * All concurrency models supported: coroutines, threads * Parallel query execution diff --git a/docker-compose.yaml b/docker-compose.yaml index 19049c9..ee000ac 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,4 +1,4 @@ -version: '3.7' +version: "3.7" services: base: &base diff --git a/docs/conf.py b/docs/conf.py index cc6f8d3..7773533 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,33 +1,31 @@ extensions = [ - 'sphinx.ext.autodoc', - 'sphinx.ext.intersphinx', + "sphinx.ext.autodoc", + "sphinx.ext.intersphinx", ] -autoclass_content = 'both' -autodoc_member_order = 'bysource' +autoclass_content = "both" +autodoc_member_order = "bysource" intersphinx_mapping = { - 'python': ('https://docs.python.org/3.6', None), - 'aiopg': ('http://aiopg.readthedocs.io/en/stable', None), - 'sqlalchemy': ('http://docs.sqlalchemy.org/en/rel_1_1', None), + "python": ("https://docs.python.org/3.6", None), + "aiopg": ("http://aiopg.readthedocs.io/en/stable", None), + "sqlalchemy": ("http://docs.sqlalchemy.org/en/rel_1_1", None), } -source_suffix = '.rst' -master_doc = 'index' +source_suffix = ".rst" +master_doc = "index" -project = 'hiku' -copyright = '2019, Vladimir Magamedov' -author = 'Vladimir Magamedov' +project = "hiku" +copyright = "2019, Vladimir Magamedov" +author = "Vladimir Magamedov" templates_path = [] -html_theme = 'furo' -html_static_path = ['_static'] -html_theme_options = { - 'display_version': False, -} +html_theme = "furo" +html_static_path = ["_static"] +html_theme_options = {} def setup(app): - app.add_css_file('style.css?r=1') - app.add_css_file('fixes.css?r=1') + app.add_css_file("style.css?r=1") + app.add_css_file("fixes.css?r=1") diff --git a/docs/reference/readers.rst b/docs/reference/readers.rst new file mode 100644 index 0000000..805c190 --- /dev/null +++ b/docs/reference/readers.rst @@ -0,0 +1,2 @@ +.. automodule:: hiku.readers.graphql + :members: read, read_operation, Operation, OperationType diff --git a/hiku/readers/graphql.py b/hiku/readers/graphql.py index 98d1ef1..8b8120d 100644 --- a/hiku/readers/graphql.py +++ b/hiku/readers/graphql.py @@ -1,3 +1,10 @@ +""" +hiku.readers.graphql +~~~~~~~~~~~~~~~~~~~~ + +Support for queries encoded using GraphQL syntax. + +""" from typing import Any, cast, Dict, Iterator, List, Optional, Set, Union from graphql.language import ast