Skip to content

Commit

Permalink
Merge pull request #116 from quickstrom/handle-end-after-error
Browse files Browse the repository at this point in the history
Handle End message after Error message
  • Loading branch information
owickstrom committed Nov 9, 2022
2 parents 19ffd6d + dcc15da commit b8352cd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions quickstrom/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,9 @@ def run_sessions() -> List[result.PlainResult]:
raise e
except Exception as e:
send(Error(str(e)))
msg = receive()
if not isinstance(msg, End):
raise Exception(f"Expected End after Error but got: {msg}")
elif isinstance(msg, Done):
return [
attach_screenshots(result.from_protocol_result(r))
Expand Down

0 comments on commit b8352cd

Please sign in to comment.