port-ocean 0.5.24__py3-none-any.whl → 0.5.24.dev1__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.
Potentially problematic release.
This version of port-ocean might be problematic. Click here for more details.
- port_ocean/core/defaults/initialize.py +1 -1
- port_ocean/core/integrations/mixins/sync_raw.py +2 -9
- port_ocean/core/utils.py +5 -11
- port_ocean/exceptions/port_defaults.py +1 -1
- {port_ocean-0.5.24.dist-info → port_ocean-0.5.24.dev1.dist-info}/METADATA +1 -1
- {port_ocean-0.5.24.dist-info → port_ocean-0.5.24.dev1.dist-info}/RECORD +9 -9
- {port_ocean-0.5.24.dist-info → port_ocean-0.5.24.dev1.dist-info}/LICENSE.md +0 -0
- {port_ocean-0.5.24.dist-info → port_ocean-0.5.24.dev1.dist-info}/WHEEL +0 -0
- {port_ocean-0.5.24.dist-info → port_ocean-0.5.24.dev1.dist-info}/entry_points.txt +0 -0
|
@@ -159,7 +159,7 @@ async def _create_resources(
|
|
|
159
159
|
f"Failed to create resources: {err.response.text}. Rolling back changes..."
|
|
160
160
|
)
|
|
161
161
|
raise AbortDefaultCreationError(
|
|
162
|
-
created_blueprints_identifiers, [err],
|
|
162
|
+
created_blueprints_identifiers, [err], created_pages
|
|
163
163
|
)
|
|
164
164
|
|
|
165
165
|
|
|
@@ -372,10 +372,7 @@ class SyncRawMixin(HandlerMixin, EventsMixin):
|
|
|
372
372
|
)
|
|
373
373
|
|
|
374
374
|
if after_errors:
|
|
375
|
-
message = (
|
|
376
|
-
f"Failed to calculate diff for entities with {len(after_errors)} errors. "
|
|
377
|
-
f"Skipping delete phase due to incomplete state"
|
|
378
|
-
)
|
|
375
|
+
message = f"Failed to calculate diff for entities with {len(after_errors)} errors. Skipping delete phase due to incomplete state"
|
|
379
376
|
logger.error(message, exc_info=after_errors)
|
|
380
377
|
entities_before_flatten = []
|
|
381
378
|
|
|
@@ -419,11 +416,7 @@ class SyncRawMixin(HandlerMixin, EventsMixin):
|
|
|
419
416
|
)
|
|
420
417
|
except httpx.HTTPError as e:
|
|
421
418
|
logger.warning(
|
|
422
|
-
"Failed to fetch the current state of entities at Port. "
|
|
423
|
-
"Skipping delete phase due to unknown initial state. "
|
|
424
|
-
f"Error: {e}\n"
|
|
425
|
-
f"Response status code: {e.response.status_code if isinstance(e, httpx.HTTPStatusError) else None}\n"
|
|
426
|
-
f"Response content: {e.response.text if isinstance(e, httpx.HTTPStatusError) else None}\n"
|
|
419
|
+
"Failed to fetch the current state of entities at Port. Skipping delete phase due to unknown initial state"
|
|
427
420
|
)
|
|
428
421
|
entities_at_port = []
|
|
429
422
|
|
port_ocean/core/utils.py
CHANGED
|
@@ -34,19 +34,13 @@ Q = TypeVar("Q")
|
|
|
34
34
|
|
|
35
35
|
async def gather_and_split_errors_from_results(
|
|
36
36
|
task: Iterable[Awaitable[Q]],
|
|
37
|
-
result_threshold_validation: Callable[[Q |
|
|
38
|
-
) -> tuple[list[Q], list[
|
|
39
|
-
valid_items
|
|
40
|
-
errors
|
|
37
|
+
result_threshold_validation: Callable[[Q | BaseException], bool] | None = None,
|
|
38
|
+
) -> tuple[list[Q], list[BaseException]]:
|
|
39
|
+
valid_items = []
|
|
40
|
+
errors = []
|
|
41
41
|
results = await asyncio.gather(*task, return_exceptions=True)
|
|
42
42
|
for item in results:
|
|
43
|
-
|
|
44
|
-
# https://docs.python.org/3/library/asyncio-task.html#asyncio.gather
|
|
45
|
-
# These exceptions should be raised and not caught for the application to exit properly.
|
|
46
|
-
# https://stackoverflow.com/a/17802352
|
|
47
|
-
if isinstance(item, BaseException):
|
|
48
|
-
raise item
|
|
49
|
-
elif isinstance(item, Exception):
|
|
43
|
+
if isinstance(item, Exception):
|
|
50
44
|
errors.append(item)
|
|
51
45
|
elif not result_threshold_validation or result_threshold_validation(item):
|
|
52
46
|
valid_items.append(item)
|
|
@@ -5,7 +5,7 @@ class AbortDefaultCreationError(BaseOceanException):
|
|
|
5
5
|
def __init__(
|
|
6
6
|
self,
|
|
7
7
|
blueprints_to_rollback: list[str],
|
|
8
|
-
errors: list[
|
|
8
|
+
errors: list[BaseException],
|
|
9
9
|
pages_to_rollback: list[str] | None = None,
|
|
10
10
|
):
|
|
11
11
|
self.blueprints_to_rollback = blueprints_to_rollback
|
|
@@ -59,7 +59,7 @@ port_ocean/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
59
59
|
port_ocean/core/defaults/__init__.py,sha256=8qCZg8n06WAdMu9s_FiRtDYLGPGHbOuS60vapeUoAks,142
|
|
60
60
|
port_ocean/core/defaults/clean.py,sha256=S3UAfca-oU89WJKIB4OgGjGjPr0vxBQ2aRZsLTZhQ04,2185
|
|
61
61
|
port_ocean/core/defaults/common.py,sha256=QnLFTkT3yIWIRtLQb7fUvvfe5AfInYJy0q5LjlzHkOw,3553
|
|
62
|
-
port_ocean/core/defaults/initialize.py,sha256=
|
|
62
|
+
port_ocean/core/defaults/initialize.py,sha256=MLzxpQ7B9OlXyIIxUkTgMJTMk_GjF6vjQoqfKzUAebc,7420
|
|
63
63
|
port_ocean/core/event_listener/__init__.py,sha256=mzJ33wRq0kh60fpVdOHVmvMTUQIvz3vxmifyBgwDn0E,889
|
|
64
64
|
port_ocean/core/event_listener/base.py,sha256=4RujgPz4VfDFlviu4qLGJFnJougSCL-Ewf0rfTQfwgc,1133
|
|
65
65
|
port_ocean/core/event_listener/factory.py,sha256=AYYfSHPAF7P5H-uQECXT0JVJjKDHrYkWJJBSL4mGkg8,3697
|
|
@@ -88,18 +88,18 @@ port_ocean/core/integrations/mixins/__init__.py,sha256=FA1FEKMM6P-L2_m7Q4L20mFa4
|
|
|
88
88
|
port_ocean/core/integrations/mixins/events.py,sha256=Ddfx2L4FpghV38waF8OfVeOV0bHBxNIgjU-q5ffillI,2341
|
|
89
89
|
port_ocean/core/integrations/mixins/handler.py,sha256=mZ7-0UlG3LcrwJttFbMe-R4xcOU2H_g33tZar7PwTv8,3771
|
|
90
90
|
port_ocean/core/integrations/mixins/sync.py,sha256=TKqRytxXONVhuCo3CB3rDvWNbITnZz33TYTDs3SWWVk,3880
|
|
91
|
-
port_ocean/core/integrations/mixins/sync_raw.py,sha256=
|
|
91
|
+
port_ocean/core/integrations/mixins/sync_raw.py,sha256=32pmbZuv-g508Qv6v9I1kLMmkzERKxTrs9nXZncfx5w,17596
|
|
92
92
|
port_ocean/core/integrations/mixins/utils.py,sha256=7y1rGETZIjOQadyIjFJXIHKkQFKx_SwiP-TrAIsyyLY,2303
|
|
93
93
|
port_ocean/core/models.py,sha256=YPIU7V3GKeDXIVkNzZn0w17YN2Akl-D8nFs-l4bEKcU,1143
|
|
94
94
|
port_ocean/core/ocean_types.py,sha256=3_d8-n626f1kWLQ_Jxw194LEyrOVupz05qs_Y1pvB-A,990
|
|
95
|
-
port_ocean/core/utils.py,sha256=
|
|
95
|
+
port_ocean/core/utils.py,sha256=4TAxSIuJ1fIO84Ttx-TSKw3SJW4Iat50I1JD4PlAwBA,2417
|
|
96
96
|
port_ocean/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
97
97
|
port_ocean/exceptions/api.py,sha256=TLmTMqn4uHGaHgZK8PMIJ0TVJlPB4iP7xl9rx7GtCyY,426
|
|
98
98
|
port_ocean/exceptions/base.py,sha256=uY4DX7fIITDFfemCJDWpaZi3bD51lcANc5swpoNvMJA,46
|
|
99
99
|
port_ocean/exceptions/clients.py,sha256=LKLLs-Zy3caNG85rwxfOw2rMr8qqVV6SHUq4fRCZ99U,180
|
|
100
100
|
port_ocean/exceptions/context.py,sha256=mA8HII6Rl4QxKUz98ppy1zX3kaziaen21h1ZWuU3ADc,372
|
|
101
101
|
port_ocean/exceptions/core.py,sha256=ygxtPQ9IG8NzIrzZok5OqkefVrqcC4bjZ-2Vf9IPZuA,790
|
|
102
|
-
port_ocean/exceptions/port_defaults.py,sha256=
|
|
102
|
+
port_ocean/exceptions/port_defaults.py,sha256=PUzxOyeKeuur_xbBmCNFl_fcSsJBdeSx6GG9TcdoJr4,545
|
|
103
103
|
port_ocean/exceptions/utils.py,sha256=gjOqpi-HpY1l4WlMFsGA9yzhxDhajhoGGdDDyGbLnqI,197
|
|
104
104
|
port_ocean/helpers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
105
105
|
port_ocean/helpers/async_client.py,sha256=SRlP6o7_FCSY3UHnRlZdezppePVxxOzZ0z861vE3K40,1783
|
|
@@ -122,8 +122,8 @@ port_ocean/utils/queue_utils.py,sha256=KWWl8YVnG-glcfIHhM6nefY-2sou_C6DVP1VynQwz
|
|
|
122
122
|
port_ocean/utils/repeat.py,sha256=0EFWM9d8lLXAhZmAyczY20LAnijw6UbIECf5lpGbOas,3231
|
|
123
123
|
port_ocean/utils/signal.py,sha256=K-6kKFQTltcmKDhtyZAcn0IMa3sUpOHGOAUdWKgx0_E,1369
|
|
124
124
|
port_ocean/version.py,sha256=UsuJdvdQlazzKGD3Hd5-U7N69STh8Dq9ggJzQFnu9fU,177
|
|
125
|
-
port_ocean-0.5.24.dist-info/LICENSE.md,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
|
|
126
|
-
port_ocean-0.5.24.dist-info/METADATA,sha256=
|
|
127
|
-
port_ocean-0.5.24.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
128
|
-
port_ocean-0.5.24.dist-info/entry_points.txt,sha256=F_DNUmGZU2Kme-8NsWM5LLE8piGMafYZygRYhOVtcjA,54
|
|
129
|
-
port_ocean-0.5.24.dist-info/RECORD,,
|
|
125
|
+
port_ocean-0.5.24.dev1.dist-info/LICENSE.md,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
|
|
126
|
+
port_ocean-0.5.24.dev1.dist-info/METADATA,sha256=qnUn24YkOxfk4BZd616CeA7XJZ2b_jQS43lSg3o3Zzo,6559
|
|
127
|
+
port_ocean-0.5.24.dev1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
128
|
+
port_ocean-0.5.24.dev1.dist-info/entry_points.txt,sha256=F_DNUmGZU2Kme-8NsWM5LLE8piGMafYZygRYhOVtcjA,54
|
|
129
|
+
port_ocean-0.5.24.dev1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|