zrb 1.5.12__py3-none-any.whl → 1.5.13__py3-none-any.whl
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.
zrb/task/base_task.py
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
import asyncio
|
2
|
+
import inspect
|
2
3
|
from collections.abc import Callable
|
3
4
|
from typing import Any
|
4
5
|
|
@@ -66,6 +67,9 @@ class BaseTask(AnyTask):
|
|
66
67
|
fallback: list[AnyTask] | AnyTask | None = None,
|
67
68
|
successor: list[AnyTask] | AnyTask | None = None,
|
68
69
|
):
|
70
|
+
caller_frame = inspect.stack()[1]
|
71
|
+
self.__decl_file = caller_frame.filename
|
72
|
+
self.__decl_line = caller_frame.lineno
|
69
73
|
self._name = name
|
70
74
|
self._color = color
|
71
75
|
self._icon = icon
|
@@ -259,5 +263,17 @@ class BaseTask(AnyTask):
|
|
259
263
|
Returns:
|
260
264
|
Any: The result of the action execution.
|
261
265
|
"""
|
262
|
-
|
263
|
-
|
266
|
+
try:
|
267
|
+
# Delegate to the helper function for the default behavior
|
268
|
+
return await run_default_action(self, ctx)
|
269
|
+
except BaseException as e:
|
270
|
+
additional_error_note = (
|
271
|
+
f"Task: {self.name} ({self.__decl_file}:{self.__decl_line})"
|
272
|
+
)
|
273
|
+
ctx.log_error(additional_error_note)
|
274
|
+
if hasattr(e, "add_note"):
|
275
|
+
e.add_note(additional_error_note)
|
276
|
+
else:
|
277
|
+
# fallback: use the __notes__ attribute directly
|
278
|
+
e.__notes__ = getattr(e, "__notes__", []) + [additional_error_note]
|
279
|
+
raise e
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: zrb
|
3
|
-
Version: 1.5.
|
3
|
+
Version: 1.5.13
|
4
4
|
Summary: Your Automation Powerhouse
|
5
5
|
Home-page: https://github.com/state-alchemists/zrb
|
6
6
|
License: AGPL-3.0-or-later
|
@@ -71,14 +71,13 @@ Install Zrb via pip:
|
|
71
71
|
|
72
72
|
```bash
|
73
73
|
pip install zrb
|
74
|
-
|
74
|
+
# pip install --pre zrb
|
75
75
|
```
|
76
76
|
|
77
77
|
Or run our installation script to set up Zrb along with all prerequisites:
|
78
78
|
|
79
79
|
```bash
|
80
80
|
bash -c "$(curl -fsSL https://raw.githubusercontent.com/state-alchemists/zrb/main/install.sh)"
|
81
|
-
|
82
81
|
```
|
83
82
|
|
84
83
|
# 🍲 Quick Start: Build Your First Automation Workflow
|
@@ -196,7 +195,6 @@ Then open your browser and visit `http://localhost:21213`
|
|
196
195
|
|
197
196
|
# 🎥 Demo & Documentation
|
198
197
|
|
199
|
-
- **Step by step guide:** [Getting started with Zrb](https://github.com/state-alchemists/zrb/blob/main/docs/recipes/getting-started/README.md).
|
200
198
|
- **Full documentation:** [Zrb Documentation](https://github.com/state-alchemists/zrb/blob/main/docs/README.md)
|
201
199
|
- **Video demo:**
|
202
200
|
|
@@ -306,7 +306,7 @@ zrb/task/base/execution.py,sha256=lB6cfivk-EM6sZSaPjYs_ufb7jb-A2jLJNhBupwBFgI,11
|
|
306
306
|
zrb/task/base/lifecycle.py,sha256=YIugyqRmEKMnc9MTCDEZr9jVhie3Kwt7LTMtAVAN9Ks,7278
|
307
307
|
zrb/task/base/monitoring.py,sha256=UAOEcPiYNtZR4FFxzWCosuOEFE_P3c4GT5vAhQmohqI,5663
|
308
308
|
zrb/task/base/operators.py,sha256=uAMFqpZJsPnCrojgOl1FUDXTS15mtOa_IqiAXltyYRU,1576
|
309
|
-
zrb/task/base_task.py,sha256=
|
309
|
+
zrb/task/base_task.py,sha256=HsFBPpagiyouRXzyxccYs1dO-dlBwBdcyqkgppZgnmw,10784
|
310
310
|
zrb/task/base_trigger.py,sha256=jC722rDvodaBLeNaFghkTyv1u0QXrK6BLZUUqcmBJ7Q,4581
|
311
311
|
zrb/task/cmd_task.py,sha256=xFAdOvLDK9Qaye40T_lG3K6AIKgbPAMHk_3GIAYeJAM,10750
|
312
312
|
zrb/task/http_check.py,sha256=Gf5rOB2Se2EdizuN9rp65HpGmfZkGc-clIAlHmPVehs,2565
|
@@ -363,7 +363,7 @@ zrb/util/string/name.py,sha256=SXEfxJ1-tDOzHqmSV8kvepRVyMqs2XdV_vyoh_9XUu0,1584
|
|
363
363
|
zrb/util/todo.py,sha256=VGISej2KQZERpornK-8X7bysp4JydMrMUTnG8B0-liI,20708
|
364
364
|
zrb/xcom/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
365
365
|
zrb/xcom/xcom.py,sha256=o79rxR9wphnShrcIushA0Qt71d_p3ZTxjNf7x9hJB78,1571
|
366
|
-
zrb-1.5.
|
367
|
-
zrb-1.5.
|
368
|
-
zrb-1.5.
|
369
|
-
zrb-1.5.
|
366
|
+
zrb-1.5.13.dist-info/METADATA,sha256=TQfp35Bm_7FlsY54TUe39XdiGHEmnWzkVeIoLyDZnb0,8347
|
367
|
+
zrb-1.5.13.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
368
|
+
zrb-1.5.13.dist-info/entry_points.txt,sha256=-Pg3ElWPfnaSM-XvXqCxEAa-wfVI6BEgcs386s8C8v8,46
|
369
|
+
zrb-1.5.13.dist-info/RECORD,,
|
File without changes
|
File without changes
|