Skip to content

Commit 26b0fc0

Browse files
authored
Update dependencies and other minor changes (#270)
1 parent f0bf2c7 commit 26b0fc0

File tree

4 files changed

+8
-9
lines changed

4 files changed

+8
-9
lines changed

graphql/error/tests/test_base.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,6 @@ def resolver(context, *_):
8989
formatted_tb = [row[2:] for row in extracted]
9090
formatted_tb = [tb for tb in formatted_tb if tb[0] != "reraise"]
9191

92-
print(formatted_tb)
93-
9492
assert formatted_tb == [
9593
("test_reraise_from_promise", "result.errors[0].reraise()"),
9694
("_resolve_from_executor", "executor(resolve, reject)"),

graphql/execution/executor.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ def on_resolve(data):
150150
return promise.get()
151151
else:
152152
clean = getattr(exe_context.executor, "clean", None)
153-
if clean:
153+
if callable(clean):
154154
clean()
155155

156156
return promise
@@ -161,7 +161,7 @@ def execute_operation(
161161
operation, # type: OperationDefinition
162162
root_value, # type: Any
163163
):
164-
# type: (...) -> Union[Dict, Promise[Dict]]
164+
# type: (...) -> Union[Dict, Promise[Dict], Observable]
165165
type = get_operation_root_type(exe_context.schema, operation)
166166
fields = collect_fields(
167167
exe_context, type, operation.selection_set, DefaultOrderedDict(list), set()
@@ -278,11 +278,11 @@ def on_error(error):
278278
def map_result(data):
279279
# type: (Dict[str, Any]) -> ExecutionResult
280280
if subscriber_exe_context.errors:
281-
result = ExecutionResult(data=data, errors=subscriber_exe_context.errors)
281+
res = ExecutionResult(data=data, errors=subscriber_exe_context.errors)
282282
else:
283-
result = ExecutionResult(data=data)
283+
res = ExecutionResult(data=data)
284284
subscriber_exe_context.reset()
285-
return result
285+
return res
286286

287287
def catch_error(error):
288288
subscriber_exe_context.errors.append(error)

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
"pytest==4.6.9",
2828
"pytest-django==3.8.0",
2929
"pytest-cov==2.8.1",
30-
"coveralls==1.10.0",
31-
"gevent==1.4.0",
30+
"coveralls==1.11.1",
31+
"gevent>=1.4.0,<1.6",
3232
"six>=1.10.0",
3333
"pytest-benchmark==3.2.3",
3434
"pytest-mock==2.0.0",

tox.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
envlist = py{27,35,36,37,py38,py,py3},pre-commit,mypy,docs
33

44
[testenv]
5+
install_command = python -m pip install --ignore-installed --pre {opts} {packages}
56
deps =
67
.[test]
78
commands =

0 commit comments

Comments
 (0)