From 933c81b7a80d544f44abe0e171545fa2c8e3ca44 Mon Sep 17 00:00:00 2001 From: jpic Date: Sun, 16 Feb 2020 15:34:44 +0100 Subject: [PATCH] Break script on error --- shlax/strategies/script.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/shlax/strategies/script.py b/shlax/strategies/script.py index 24ac09b..bd8b0d7 100644 --- a/shlax/strategies/script.py +++ b/shlax/strategies/script.py @@ -29,4 +29,6 @@ class Script(Action): async def call(self, *args, **kwargs): for action in self.actions: - await action(*args, **kwargs) + result = await action(*args, **kwargs) + if action.status != 'success': + break