arpakitlib 1.6.97__py3-none-any.whl → 1.6.99__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.
- arpakitlib/ar_base_worker_util.py +0 -28
- arpakitlib/ar_sqlalchemy_util.py +1 -2
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/METADATA +1 -1
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/RECORD +8 -8
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/LICENSE +0 -0
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/NOTICE +0 -0
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/WHEEL +0 -0
- {arpakitlib-1.6.97.dist-info → arpakitlib-1.6.99.dist-info}/entry_points.txt +0 -0
@@ -56,29 +56,14 @@ class BaseWorker(ABC):
|
|
56
56
|
self._logger.exception(exception)
|
57
57
|
|
58
58
|
def sync_safe_run(self):
|
59
|
-
self._logger.info(f"start sync_safe_run")
|
60
|
-
|
61
|
-
self._logger.info("start sync_on_startup ")
|
62
59
|
self.sync_on_startup()
|
63
|
-
self._logger.info("finish sync_on_startup")
|
64
|
-
|
65
60
|
while True:
|
66
|
-
|
67
61
|
try:
|
68
|
-
|
69
|
-
self._logger.info("start sync_run")
|
70
62
|
self.sync_run()
|
71
|
-
self._logger.info("finish sync_run")
|
72
|
-
|
73
63
|
if self.timeout_after_run is not None:
|
74
64
|
sync_safe_sleep(self.timeout_after_run)
|
75
|
-
|
76
65
|
except BaseException as exception:
|
77
|
-
|
78
|
-
self._logger.info("start sync_run_on_error")
|
79
66
|
self.sync_run_on_error(exception=exception)
|
80
|
-
self._logger.info("start sync_run_on_error")
|
81
|
-
|
82
67
|
if self.timeout_after_err_in_run is not None:
|
83
68
|
sync_safe_sleep(self.timeout_after_err_in_run)
|
84
69
|
|
@@ -92,27 +77,14 @@ class BaseWorker(ABC):
|
|
92
77
|
self._logger.exception(exception)
|
93
78
|
|
94
79
|
async def async_safe_run(self):
|
95
|
-
self._logger.info(f"start async_safe_run")
|
96
|
-
|
97
|
-
self._logger.info("start async_on_startup")
|
98
80
|
await self.async_on_startup()
|
99
|
-
self._logger.info("start async_on_startup")
|
100
|
-
|
101
81
|
while True:
|
102
|
-
|
103
82
|
try:
|
104
|
-
|
105
83
|
await self.async_run()
|
106
|
-
|
107
84
|
if self.timeout_after_run is not None:
|
108
85
|
await async_safe_sleep(self.timeout_after_run)
|
109
|
-
|
110
86
|
except BaseException as exception:
|
111
|
-
|
112
|
-
self._logger.info("start async_run_on_error")
|
113
87
|
await self.async_run_on_error(exception=exception)
|
114
|
-
self._logger.info("finish async_run_on_error")
|
115
|
-
|
116
88
|
if self.timeout_after_err_in_run is not None:
|
117
89
|
await async_safe_sleep(self.timeout_after_err_in_run)
|
118
90
|
|
arpakitlib/ar_sqlalchemy_util.py
CHANGED
@@ -10,7 +10,6 @@ from sqlalchemy.orm import sessionmaker, DeclarativeBase
|
|
10
10
|
from sqlalchemy.orm.session import Session
|
11
11
|
|
12
12
|
from arpakitlib.ar_datetime_util import now_utc_dt
|
13
|
-
from arpakitlib.ar_sqlalchemy_model_util import BaseDBM
|
14
13
|
|
15
14
|
_ARPAKIT_LIB_MODULE_VERSION = "3.0"
|
16
15
|
|
@@ -30,7 +29,7 @@ class SQLAlchemyDB:
|
|
30
29
|
echo: bool = False,
|
31
30
|
need_include_operation_dbm: bool = False,
|
32
31
|
need_include_story_dbm: bool = False,
|
33
|
-
models: list[
|
32
|
+
models: list[Any] = None
|
34
33
|
):
|
35
34
|
self._logger = logging.getLogger(self.__class__.__name__)
|
36
35
|
self.need_include_operation_dbm = need_include_operation_dbm
|
@@ -71,7 +71,7 @@ arpakitlib/ar_arpakit_lib_module_util.py,sha256=V_mc3Ml73Tzz3arxmwEfIxruKMyrwbe8
|
|
71
71
|
arpakitlib/ar_arpakit_schedule_uust_api_client_util.py,sha256=SYWWQDohPnw0qpBIu2hEvGZRVdaI4NUUQdEjnMnseo4,18237
|
72
72
|
arpakitlib/ar_arpakitlib_cli.py,sha256=T-YGAL6hRdrT2x3ug33N3GrWLYKSjK25r9SlaiBT7-M,2366
|
73
73
|
arpakitlib/ar_base64_util.py,sha256=aZkg2cZTuAaP2IWeG_LXJ6RO7qhyskVwec-Lks0iM-k,676
|
74
|
-
arpakitlib/ar_base_worker_util.py,sha256=
|
74
|
+
arpakitlib/ar_base_worker_util.py,sha256=fW7kzbo7gKFaF7-l7DnOGTVkt4H_BeHSkTHSoGQR8Fw,3295
|
75
75
|
arpakitlib/ar_cache_file_util.py,sha256=Fo2pH-Zqm966KWFBHG_pbiySGZvhIFCYqy7k1weRfJ0,3476
|
76
76
|
arpakitlib/ar_datetime_util.py,sha256=Xe1NiT9oPQzNSG7RVRkhukhbg4i-hhS5ImmV7sPUc8o,971
|
77
77
|
arpakitlib/ar_dict_util.py,sha256=cF5LQJ6tLqyGoEXfDljMDZrikeZoWPw7CgINHIFGvXM,419
|
@@ -122,15 +122,15 @@ arpakitlib/ar_schedule_uust_api_client_util.py,sha256=JD-hRUQSs-euK0zq9w_4QUfGO0
|
|
122
122
|
arpakitlib/ar_settings_util.py,sha256=NvFzpIaQhlMp-BZwttUY_9gamMC5cpJk2Kp2B3BtMug,1296
|
123
123
|
arpakitlib/ar_sleep_util.py,sha256=9ZN4Qo4eZ_q3hjM7vNBQjFRcH-9-sqv3QLSjnxVJE90,1405
|
124
124
|
arpakitlib/ar_sqlalchemy_model_util.py,sha256=ttdgOwQfoHTKqgivBtXoSbJoBCASHDjLEFK5tJ9kNNE,4779
|
125
|
-
arpakitlib/ar_sqlalchemy_util.py,sha256=
|
125
|
+
arpakitlib/ar_sqlalchemy_util.py,sha256=nBMW9BDfPNsvaPs7tQ6NR1psL4H9eDrm6aZMppSmu3g,4191
|
126
126
|
arpakitlib/ar_ssh_runner_util.py,sha256=jlnss4V4pziBN1rBzoK_lDiWm6nMOqGXfa6NFJSKH-Y,6796
|
127
127
|
arpakitlib/ar_str_util.py,sha256=AhcdrEm-pXRilCaDWCdTfVkQSy0SnbE52ur43Ltr6cI,2128
|
128
128
|
arpakitlib/ar_type_util.py,sha256=5nDnXL5Oyozlg8XvxMrogsoYiG8_atItg46A0mtv-pk,2025
|
129
129
|
arpakitlib/ar_yookassa_api_client_util.py,sha256=sh4fcUkAkdOetFn9JYoTvjcSXP-M1wU04KEY-ECLfLg,5137
|
130
130
|
arpakitlib/ar_zabbix_api_client_util.py,sha256=Q-VR4MvoZ9aHwZeYZr9G3LwN-ANx1T5KFmF6pvPM-9M,6402
|
131
|
-
arpakitlib-1.6.
|
132
|
-
arpakitlib-1.6.
|
133
|
-
arpakitlib-1.6.
|
134
|
-
arpakitlib-1.6.
|
135
|
-
arpakitlib-1.6.
|
136
|
-
arpakitlib-1.6.
|
131
|
+
arpakitlib-1.6.99.dist-info/LICENSE,sha256=GPEDQMam2r7FSTYqM1mm7aKnxLaWcBotH7UvQtea-ec,11355
|
132
|
+
arpakitlib-1.6.99.dist-info/METADATA,sha256=dsQmR-Tk0bGhd7AODaw00J8AXOJk0TffL3RA7m2bp8Q,2739
|
133
|
+
arpakitlib-1.6.99.dist-info/NOTICE,sha256=95aUzaPJjVpDsGAsNzVnq7tHTxAl0s5UFznCTkVCau4,763
|
134
|
+
arpakitlib-1.6.99.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
135
|
+
arpakitlib-1.6.99.dist-info/entry_points.txt,sha256=VHkTDXDOMrgcNzGfKhEhoOIIz6T8Kkt46hy95Zc1iL0,74
|
136
|
+
arpakitlib-1.6.99.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|