graphql-http 1.6.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2019 Robert Parker
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,4 @@
1
+ include README.md
2
+ include VERSION
3
+ include graphql_http/graphiql/index.html
4
+ include graphql_http/service/service_manager_default.graphql
@@ -0,0 +1,40 @@
1
+ Metadata-Version: 2.4
2
+ Name: graphql_http
3
+ Version: 1.6.2
4
+ Summary: HTTP Server for GraphQL.
5
+ Home-page: https://gitlab.com/parob/graphql-http
6
+ Download-URL: https://gitlab.com/parob/graphql-http/-/archive/master/graphql-http-v1.6.2.zip
7
+ Author: Robert Parker
8
+ Author-email: rob@parob.com
9
+ License: MIT
10
+ Keywords: GraphQL,HTTP,Server,werkzeug
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: License :: OSI Approved :: MIT License
15
+ Classifier: Operating System :: OS Independent
16
+ Description-Content-Type: text/markdown
17
+ License-File: LICENSE
18
+ Requires-Dist: graphql-core>=3.2.0
19
+ Requires-Dist: graphql-api>=1.3.0
20
+ Requires-Dist: werkzeug>=2.2.2
21
+ Requires-Dist: context-helper>=1.0.2
22
+ Requires-Dist: packaging>=21.3
23
+ Requires-Dist: graphql-schema-diff>=1.2.4
24
+ Requires-Dist: pyjwt[crypto]==2.7.0
25
+ Dynamic: author
26
+ Dynamic: author-email
27
+ Dynamic: classifier
28
+ Dynamic: description
29
+ Dynamic: description-content-type
30
+ Dynamic: download-url
31
+ Dynamic: home-page
32
+ Dynamic: keywords
33
+ Dynamic: license
34
+ Dynamic: license-file
35
+ Dynamic: requires-dist
36
+ Dynamic: summary
37
+
38
+ # GraphQL HTTP Web Server
39
+
40
+ Minimal adapter to respond to HTTP requests with a GraphQL schema.
@@ -0,0 +1,3 @@
1
+ # GraphQL HTTP Web Server
2
+
3
+ Minimal adapter to respond to HTTP requests with a GraphQL schema.
@@ -0,0 +1 @@
1
+ 1.6.2
@@ -0,0 +1,3 @@
1
+ from .server import GraphQLHTTP
2
+
3
+ __all__ = ["GraphQLHTTP"]
@@ -0,0 +1,19 @@
1
+ class HttpQueryError(Exception):
2
+ def __init__(self, status_code, message=None, is_graphql_error=False, headers=None):
3
+ self.status_code = status_code
4
+ self.message = message
5
+ self.is_graphql_error = is_graphql_error
6
+ self.headers = headers
7
+ super(HttpQueryError, self).__init__(message)
8
+
9
+ def __eq__(self, other):
10
+ return (
11
+ isinstance(other, HttpQueryError)
12
+ and other.status_code == self.status_code
13
+ and other.message == self.message
14
+ and other.headers == self.headers
15
+ )
16
+
17
+ def __hash__(self):
18
+ headers_hash = tuple(self.headers.items()) if self.headers else None
19
+ return hash((self.status_code, self.message, headers_hash))