Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
114 changed files
with
3,481 additions
and
1,725 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,5 +4,6 @@ venv | |
.cache | ||
.idea | ||
.pytest_cache/ | ||
.mypy_cache/ | ||
|
||
docs/_build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
language: python | ||
sudo: required | ||
dist: xenial | ||
python: | ||
- 3.6 | ||
- 3.7 | ||
install: | ||
- pip install -r requirements.txt | ||
script: | ||
- pytest --cov | ||
- flake8 slothql | ||
# - mypy . | ||
after_success: | ||
- pip install coveralls | ||
- coveralls |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[mypy] | ||
python_version = 3.7 | ||
warn_return_any = True | ||
warn_unused_configs = True | ||
ignore_missing_imports = True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,22 @@ | ||
graphql-core>=2<3 | ||
cached-property==1.4 | ||
cached-property==1.5.1 | ||
|
||
# optional | ||
django>=2.0<3 | ||
django>=2.0 | ||
psycopg2-binary>=2.7<3 | ||
|
||
# development | ||
pytest | ||
pytest-cov | ||
pytest-django | ||
# testing | ||
pytest==3.8.2 | ||
pytest-cov==2.6.0 | ||
pytest-django==3.4.3 | ||
|
||
flake8 | ||
flake8-comprehensions | ||
flake8-commas | ||
flake8-quotes | ||
# QA | ||
mypy==0.630 | ||
flake8==3.5.0 | ||
flake8-comprehensions==1.4.1 | ||
black==18.9b0 | ||
|
||
# documentation | ||
sphinx | ||
recommonmark # markdown support | ||
sphinx-rtd-theme | ||
sphinx==1.8.1 | ||
recommonmark==0.4.0 # markdown support | ||
sphinx-rtd-theme==0.4.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,30 @@ | ||
from distutils.core import setup | ||
from setuptools import find_packages | ||
|
||
VERSION = '0.1.0a0' | ||
VERSION = "0.1.0a0" | ||
|
||
setup( | ||
name='slothql', | ||
name="slothql", | ||
version=VERSION, | ||
description='The async GraphQL framework.', | ||
long_description=open('README.rst').read(), | ||
|
||
author='Karol Gruszczyk', | ||
author_email='karol.gruszczyk@gmail.com', | ||
|
||
packages=find_packages(exclude=['*.tests*']), | ||
|
||
url='https://github.com/IndioInc/slothql/', | ||
keywords='graphql framework django async aiohttp relay graphene', | ||
|
||
license='MIT', | ||
description="The async GraphQL framework.", | ||
long_description=open("README.rst").read(), | ||
author="Karol Gruszczyk", | ||
author_email="karol.gruszczyk@gmail.com", | ||
packages=find_packages(exclude=["*.tests*"]), | ||
url="https://github.com/IndioInc/slothql/", | ||
keywords="graphql framework django async aiohttp relay graphene", | ||
license="MIT", | ||
classifiers=[ | ||
'Development Status :: 4 - Beta', | ||
'Programming Language :: Python :: 3 :: Only', | ||
'Programming Language :: Python :: 3', | ||
'Programming Language :: Python :: 3.6', | ||
'Programming Language :: Python :: 3.7', | ||
'License :: OSI Approved :: MIT License', | ||
'Operating System :: OS Independent', | ||
], | ||
python_requires='~=3.6', | ||
|
||
install_requires=[ | ||
'graphql-core>=2.0,<3', | ||
"Development Status :: 4 - Beta", | ||
"Programming Language :: Python :: 3 :: Only", | ||
"Programming Language :: Python :: 3", | ||
"Programming Language :: Python :: 3.6", | ||
"Programming Language :: Python :: 3.7", | ||
"License :: OSI Approved :: MIT License", | ||
"Operating System :: OS Independent", | ||
], | ||
platforms='any', | ||
python_requires="~=3.6", | ||
install_requires=["graphql-core>=2.0,<3"], | ||
platforms="any", | ||
include_package_data=True, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,58 @@ | ||
from graphql import ResolveInfo | ||
|
||
from .types.fields import Field, Integer, Float, String, Boolean, ID, JsonString, DateTime, Date, Time | ||
from .resolution import ( | ||
Resolver, | ||
ResolveArgs, | ||
PartialResolver, | ||
Selection, | ||
ResolveInfo, | ||
FilterExpression, | ||
FilterOperator, | ||
) | ||
from .types.fields import ( | ||
Field, | ||
Integer, | ||
Float, | ||
String, | ||
Boolean, | ||
ID, | ||
JsonString, | ||
DateTime, | ||
Date, | ||
Time, | ||
) | ||
from .types import BaseType, Object, Enum, EnumValue, Union | ||
from .schema import Schema | ||
from .operation import Operation, InvalidOperation | ||
from .query import gql, ExecutionResult | ||
|
||
__all__ = ( | ||
# graphql | ||
'ResolveInfo', | ||
|
||
# resolution | ||
"Resolver", | ||
"PartialResolver", | ||
"ResolveArgs", | ||
"Selection", | ||
"ResolveInfo", | ||
"FilterExpression", | ||
"FilterOperator", | ||
# fields | ||
'Field', | ||
'Integer', | ||
'Float', | ||
'String', | ||
'Boolean', | ||
'ID', | ||
'JsonString', | ||
'DateTime', | ||
'Date', | ||
'Time', | ||
|
||
"Field", | ||
"Integer", | ||
"Float", | ||
"String", | ||
"Boolean", | ||
"ID", | ||
"JsonString", | ||
"DateTime", | ||
"Date", | ||
"Time", | ||
# types | ||
'BaseType', | ||
'Object', | ||
'Enum', | ||
'EnumValue', | ||
'Union', | ||
|
||
'Operation', | ||
'InvalidOperation', | ||
'Schema', | ||
'gql', | ||
'ExecutionResult', | ||
"BaseType", | ||
"Object", | ||
"Enum", | ||
"EnumValue", | ||
"Union", | ||
"Operation", | ||
"InvalidOperation", | ||
"Schema", | ||
"gql", | ||
"ExecutionResult", | ||
) | ||
|
||
try: | ||
from slothql import django | ||
__all__ += ('django',) | ||
except ImportError as e: | ||
if str(e) != "No module named 'django'": | ||
raise |
Oops, something went wrong.