Commit b3010f91 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

Add type annotations

parent 5a804eaf
Pipeline #9146 failed with stages
in 36 seconds
......@@ -936,7 +936,7 @@ class Protocol(Node):
"""
self.setAttr('id', val)
def getError(self):
def getError(self) -> Optional[str]:
"""
Return the error-condition (if present) or the textual description
of the error (otherwise)
......
......@@ -267,7 +267,7 @@ class Task:
return self._error
return self._result
def finish(self):
def finish(self) -> Any:
if self._error is not None:
raise self._error # pylint: disable=raising-bad-type
return self._result
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment