qontract-reconcile 0.10.1rc755__py3-none-any.whl → 0.10.1rc757__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.
- {qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/METADATA +1 -1
- {qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/RECORD +8 -8
- reconcile/ocm_aws_infrastructure_access.py +1 -1
- reconcile/templating/renderer.py +10 -9
- reconcile/test/test_openshift_base.py +1 -1
- {qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/WHEEL +0 -0
- {qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/entry_points.txt +0 -0
- {qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/top_level.txt +0 -0
{qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/METADATA
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: qontract-reconcile
|
3
|
-
Version: 0.10.
|
3
|
+
Version: 0.10.1rc757
|
4
4
|
Summary: Collection of tools to reconcile services with their desired state as defined in the app-interface DB.
|
5
5
|
Home-page: https://github.com/app-sre/qontract-reconcile
|
6
6
|
Author: Red Hat App-SRE Team
|
{qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/RECORD
RENAMED
@@ -54,7 +54,7 @@ reconcile/mr_client_gateway.py,sha256=WhjMd-sIXDFCV8-rt8CEjurJ5OYB1pOD0K3o0tZRXQ
|
|
54
54
|
reconcile/ocm_additional_routers.py,sha256=KfcFDVbNoc6n5dHWjYdAf1_DiVqVG6Tw23WLKoV8cdg,3306
|
55
55
|
reconcile/ocm_addons.py,sha256=qqAyqRBRbdZQvAcjb-QlSVyRAyQBZk6iVlgnI4jyi7s,3353
|
56
56
|
reconcile/ocm_addons_upgrade_tests_trigger.py,sha256=L1ktYynIR7pmHiYtdCTdLGJRKX72B54KUAuPLOccXzo,3995
|
57
|
-
reconcile/ocm_aws_infrastructure_access.py,sha256=
|
57
|
+
reconcile/ocm_aws_infrastructure_access.py,sha256=kDnJP6aOFO263LSbdCxJMmUwVsM3LgdzebtIUOoIhH8,7130
|
58
58
|
reconcile/ocm_clusters.py,sha256=YWfBF25E55Odm0L3dXnqRbC_bDuYIsBPg4j6DEpWCGw,16703
|
59
59
|
reconcile/ocm_external_configuration_labels.py,sha256=imEpDv1RBpCSj8tHDv0R76hmNCFtcUzVNgS1yOVl8vs,3870
|
60
60
|
reconcile/ocm_github_idp.py,sha256=glwXMsIBcl38-OmDDQCpe0YoLLXfoRgVQmqwXMEXjds,3946
|
@@ -426,7 +426,7 @@ reconcile/templates/jira-checkpoint-missinginfo.j2,sha256=c_Vvg-lEENsB3tgxm9B6Y9
|
|
426
426
|
reconcile/templates/rosa-classic-cluster-creation.sh.j2,sha256=0UHfYtXRVJqP07VJQx456cRI6EbZNBgamtP_8nb4WPY,2353
|
427
427
|
reconcile/templates/rosa-hcp-cluster-creation.sh.j2,sha256=O7Bf3WQIJhsZoEqaYA0wRktUO4yXXCb4BQkuvvp-C80,2385
|
428
428
|
reconcile/templating/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
429
|
-
reconcile/templating/renderer.py,sha256=
|
429
|
+
reconcile/templating/renderer.py,sha256=xDuEOD6OBAaBYQzDcQ8ptwZQaarhHa-y1knN4d2xzkY,10598
|
430
430
|
reconcile/templating/validator.py,sha256=pvDEc6veznEZzjypkoRJUGMMFLWosU-zd7i3j7JeNjE,4670
|
431
431
|
reconcile/templating/lib/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
432
432
|
reconcile/templating/lib/merge_request_manager.py,sha256=JUkfF3smaQ8onzKF5F7UpmA7MWaQpftANy6dDo1FCug,5464
|
@@ -476,7 +476,7 @@ reconcile/test/test_ocm_clusters_manifest_updates.py,sha256=jFRVfc5jby1kI2x_gT6w
|
|
476
476
|
reconcile/test/test_ocm_machine_pools.py,sha256=3qo6t2Jfr1Wee0NUacyLTDmatp0o7CUNpkVOpHiOiGk,29737
|
477
477
|
reconcile/test/test_ocm_update_recommended_version.py,sha256=iA4BVirTGVXlwcOyeR52IuNO81X_8NR6ZNd7ZFE7igs,4328
|
478
478
|
reconcile/test/test_ocm_upgrade_scheduler_org_updater.py,sha256=V91g2XQMa2nvKwkLVWkiPwNL6pMQE16s4jO0oXJ6wdk,4330
|
479
|
-
reconcile/test/test_openshift_base.py,sha256=
|
479
|
+
reconcile/test/test_openshift_base.py,sha256=YgTKcLmzmt9oR12s_022LAp9qr1R_CBOppYwoknspzE,33868
|
480
480
|
reconcile/test/test_openshift_cluster_bots.py,sha256=L-yuKvMgB0LBCdfLu7wozh_lk6S_m3umXt3m_ECfLEI,8023
|
481
481
|
reconcile/test/test_openshift_namespace_labels.py,sha256=P1hqi6P88NijNrurdXG_QR2usyo3EYZSy9zpwYHvDsM,12104
|
482
482
|
reconcile/test/test_openshift_namespaces.py,sha256=HmRnCE5EnFt3MYceVEFHmk8wWRtCrxu2AFGFkY9pdyA,9214
|
@@ -783,8 +783,8 @@ tools/test/test_app_interface_metrics_exporter.py,sha256=SX7qL3D1SIRKFo95FoQztvf
|
|
783
783
|
tools/test/test_qontract_cli.py,sha256=w2l4BHB09k1d-BGJ1jBUNCqDv7zkqYrMHojQXg-21kQ,4155
|
784
784
|
tools/test/test_sd_app_sre_alert_report.py,sha256=v363r9zM7__0kR5K6mvJoGFcM9BvE33fWAayrqkpojA,2116
|
785
785
|
tools/test/test_sre_checkpoints.py,sha256=SKqPPTl9ua0RFdSSofnoQX-JZE6dFLO3LRhfQzqtfh8,2607
|
786
|
-
qontract_reconcile-0.10.
|
787
|
-
qontract_reconcile-0.10.
|
788
|
-
qontract_reconcile-0.10.
|
789
|
-
qontract_reconcile-0.10.
|
790
|
-
qontract_reconcile-0.10.
|
786
|
+
qontract_reconcile-0.10.1rc757.dist-info/METADATA,sha256=0L4M3FIacdQTzZZs5uNpBMpcjoUWVgkQetpJ--aadfA,2382
|
787
|
+
qontract_reconcile-0.10.1rc757.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
788
|
+
qontract_reconcile-0.10.1rc757.dist-info/entry_points.txt,sha256=rIxI5zWtHNlfpDeq1a7pZXAPoqf7HG32KMTN3MeWK_8,429
|
789
|
+
qontract_reconcile-0.10.1rc757.dist-info/top_level.txt,sha256=l5ISPoXzt0SdR4jVdkfa7RPSKNc8zAHYWAnR-Dw8Ey8,24
|
790
|
+
qontract_reconcile-0.10.1rc757.dist-info/RECORD,,
|
@@ -140,7 +140,7 @@ def act(
|
|
140
140
|
dry_run, ocm_map, current_state, current_failed, desired_state, current_deleting
|
141
141
|
):
|
142
142
|
to_delete = [c for c in current_state if c not in desired_state]
|
143
|
-
to_delete
|
143
|
+
to_delete += current_failed
|
144
144
|
for item in to_delete:
|
145
145
|
cluster = item["cluster"]
|
146
146
|
user_arn = item["user_arn"]
|
reconcile/templating/renderer.py
CHANGED
@@ -1,5 +1,3 @@
|
|
1
|
-
import hashlib
|
2
|
-
import json
|
3
1
|
import logging
|
4
2
|
import os
|
5
3
|
import tempfile
|
@@ -7,6 +5,7 @@ from abc import ABC, abstractmethod
|
|
7
5
|
from collections.abc import Callable
|
8
6
|
from typing import Any, Optional, Self
|
9
7
|
|
8
|
+
from deepdiff import DeepHash
|
10
9
|
from ruamel import yaml
|
11
10
|
|
12
11
|
from reconcile.gql_definitions.templating.template_collection import (
|
@@ -175,6 +174,14 @@ def unpack_dynamic_variables(
|
|
175
174
|
}
|
176
175
|
|
177
176
|
|
177
|
+
def calc_template_hash(c: TemplateCollectionV1, variables: dict[str, Any]) -> str:
|
178
|
+
hashable = {
|
179
|
+
"templates": sorted(c.templates, key=lambda x: x.name),
|
180
|
+
"variables": variables,
|
181
|
+
}
|
182
|
+
return DeepHash(hashable)[hashable]
|
183
|
+
|
184
|
+
|
178
185
|
class TemplateRendererIntegrationParams(PydanticRunParams):
|
179
186
|
clone_repo: bool = False
|
180
187
|
app_interface_data_path: Optional[str]
|
@@ -246,16 +253,10 @@ class TemplateRendererIntegration(QontractReconcileIntegration):
|
|
246
253
|
"static": unpack_static_variables(c.variables),
|
247
254
|
}
|
248
255
|
|
249
|
-
template_hash = hashlib.sha256(
|
250
|
-
"".join(
|
251
|
-
sorted([str(t) for t in c.templates] + [json.dumps(variables)])
|
252
|
-
).encode("utf-8")
|
253
|
-
).hexdigest()
|
254
|
-
|
255
256
|
with PersistenceTransaction(persistence, dry_run) as p:
|
256
257
|
input = TemplateInput(
|
257
258
|
collection=c.name,
|
258
|
-
collection_hash=
|
259
|
+
collection_hash=calc_template_hash(c, variables),
|
259
260
|
enable_auto_approval=c.enable_auto_approval or False,
|
260
261
|
labels=c.additional_mr_labels or [],
|
261
262
|
)
|
File without changes
|
File without changes
|
{qontract_reconcile-0.10.1rc755.dist-info → qontract_reconcile-0.10.1rc757.dist-info}/top_level.txt
RENAMED
File without changes
|