qontract-reconcile 0.10.1rc727__py3-none-any.whl → 0.10.1rc729__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: qontract-reconcile
3
- Version: 0.10.1rc727
3
+ Version: 0.10.1rc729
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
@@ -9,7 +9,7 @@ reconcile/aws_iam_password_reset.py,sha256=NwErtrqgBiXr7eGCAHdtGGOx0S7-4JnSc29Ie
9
9
  reconcile/aws_support_cases_sos.py,sha256=Jk6_XjDeJSYxgRGqcEAOcynt9qJF2r5HPIPcSKmoBv8,2974
10
10
  reconcile/blackbox_exporter_endpoint_monitoring.py,sha256=W_VJagnsJR1v5oqjlI3RJJE0_nhtJ0m81RS8zWA5u5c,3538
11
11
  reconcile/checkpoint.py,sha256=R2WFXUXLTB4sWMi4GeA4eegsuf_1-Q4vH8M0Toh3Ij4,5036
12
- reconcile/cli.py,sha256=xAuxjbBPlIeFAnyOhhMYJTthVM_J26Sb6F2WNCb734M,96573
12
+ reconcile/cli.py,sha256=lAZ68_w6IcvXfB6C8D97DtdRlpodqjrCGLLYGvRUkSs,96887
13
13
  reconcile/closedbox_endpoint_monitoring_base.py,sha256=SMhkcQqprWvThrIJa3U_3uh5w1h-alleW1QnCJFY4Qw,4909
14
14
  reconcile/cluster_deployment_mapper.py,sha256=2Ah-nu-Mdig0pjuiZl_XLrmVAjYzFjORR3dMlCgkmw0,2352
15
15
  reconcile/dashdotdb_base.py,sha256=a5aPLVxyqPSbjdB0Ty-uliOtxwvEbbEljHJKxdK3-Zk,4813
@@ -372,7 +372,7 @@ reconcile/oum/models.py,sha256=0ZyCnULRxAbIEXX60BkkPZVg53DCD6ZJ6wnNT2ANROM,1743
372
372
  reconcile/oum/providers.py,sha256=3kEjXvsTPzXc7gzrdO7hWqgzcMmMZMpk2S0X7wQUTWU,1767
373
373
  reconcile/oum/standalone.py,sha256=bzyV8wz3SrERG9zJRFiJCBzSIGwDNj9sNqUytngDw94,7368
374
374
  reconcile/prometheus_rules_tester/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
375
- reconcile/prometheus_rules_tester/integration.py,sha256=AahzQ0wEO8VEWqeT-xtmDmG6NMgMdr54jymlcqehwGM,9366
375
+ reconcile/prometheus_rules_tester/integration.py,sha256=gC0SwbppNryBZv3o0A2yTGtWQ_4ZQG4PPXZpnOA7TRo,9367
376
376
  reconcile/rhidp/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
377
377
  reconcile/rhidp/common.py,sha256=suTh9T4dPOgrKi-rDALgjzCSL9JHGnkTYALFIIjNCJE,6801
378
378
  reconcile/rhidp/metrics.py,sha256=Yp0GtpjhieEdru0qkG3osBTJiKUzg6CAjwPoFTQDnCg,417
@@ -574,7 +574,7 @@ reconcile/typed_queries/terraform_tgw_attachments/__init__.py,sha256=47DEQpj8HBS
574
574
  reconcile/typed_queries/terraform_tgw_attachments/aws_accounts.py,sha256=T5HSeyBcGKP-LzDmIzs-WlBwOtSenYpm0Odw5--xdOg,410
575
575
  reconcile/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
576
576
  reconcile/utils/aggregated_list.py,sha256=pkYoBj7WwmaNgEefETqEOFTnQMcUzHE3mdsVdzGYj60,3372
577
- reconcile/utils/amtool.py,sha256=JV5-to_e_FaIcvJWTKYA9d6L3LwzwijM0MjUWn83eD4,2204
577
+ reconcile/utils/amtool.py,sha256=Rg6_TTvuS7M2QbOkIjy2sRetvf6aNVdv_DA9ugSgMi4,2303
578
578
  reconcile/utils/aws_api.py,sha256=3VLg_MBih9SY9u43ZFbsaFNbDr086CJ7qQdTCfA-Rjo,66258
579
579
  reconcile/utils/aws_helper.py,sha256=MDbv5jrNdqqJ5pfBxniGdJXBBO_EYc2_Uf2w9ZzeMNs,2854
580
580
  reconcile/utils/binary.py,sha256=EsOGg82Y2QJh91SGJE0tYpBKqU0iaaagQVoYONBtQn8,2359
@@ -631,7 +631,7 @@ reconcile/utils/parse_dhms_duration.py,sha256=TONpLnec5gHeF7k815YNJpQyDjXhkxZIcv
631
631
  reconcile/utils/password_validator.py,sha256=XwuWg-8CPlcuG7dl_oQ1G1h2gSVSnfMym_VkuprpWVg,2183
632
632
  reconcile/utils/prometheus.py,sha256=i5aCQ_I4WOg76iEjglVxxO9-OKby2N80ScErAbDtHE8,3848
633
633
  reconcile/utils/promotion_state.py,sha256=avYxHUf4zK3dBhXEdUEry79EOSgJ7gfStvvOpcedZnI,2575
634
- reconcile/utils/promtool.py,sha256=IYNCjj5xDAEdxv6Z0pLdrIcybDfHHtWE9Z6f4LSPcG4,2791
634
+ reconcile/utils/promtool.py,sha256=kT2rFZSBaRqW7SSHAuYzGZzQxM5Dzk8KW1NnEUYZU_s,2896
635
635
  reconcile/utils/quay_api.py,sha256=EuOegpb-7ntEjkKLFwM2Oo4Nw7SyFtmyl3sQ9aXMtrM,8152
636
636
  reconcile/utils/raw_github_api.py,sha256=ZHC-SZuAyRe1zaMoOU7Krt1-zecDxENd9c_NzQYqK9g,2968
637
637
  reconcile/utils/repo_owners.py,sha256=j-pUjc9PuDzq7KpjNLpnhqfU8tUG4nj2WMhFp4ick7g,6629
@@ -746,7 +746,7 @@ tools/app_interface_metrics_exporter.py,sha256=zkwkxdAUAxjdc-pzx2_oJXG25fo0Fnyd5
746
746
  tools/app_interface_reporter.py,sha256=upA-J-n-HXHKVDINRuMR7vTt-iJvQORKUVi9D3leQto,17738
747
747
  tools/glitchtip_access_reporter.py,sha256=oPBnk_YoDuljU3v0FaChzOwwnk4vap1xEE67QEjzdqs,2948
748
748
  tools/glitchtip_access_revalidation.py,sha256=8kbBJk04mkq28kWoRDDkfCGIF3GRg3pJrFAh1sW0dbk,2821
749
- tools/qontract_cli.py,sha256=vm1uti_uMmPKiDE2gP_VXqoURqrq5YmIFZhQU6u3p2U,115670
749
+ tools/qontract_cli.py,sha256=eZONmZCLrSgMQFKHKxElDmw2_4Ld-Ug-FEFR2c8QnXI,116018
750
750
  tools/sd_app_sre_alert_report.py,sha256=e9vAdyenUz2f5c8-z-5WY0wv-SJ9aePKDH2r4IwB6pc,5063
751
751
  tools/template_validation.py,sha256=-U-lTGeLaci8yWPEblCJeev2DOlY1jM9QOOh-O1zts8,3376
752
752
  tools/cli_commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -764,8 +764,8 @@ tools/test/test_app_interface_metrics_exporter.py,sha256=SX7qL3D1SIRKFo95FoQztvf
764
764
  tools/test/test_qontract_cli.py,sha256=UEwAW7PA_GIrbqzaLxpkCxbuVjEFLNvnVG-6VyoCGIc,4147
765
765
  tools/test/test_sd_app_sre_alert_report.py,sha256=v363r9zM7__0kR5K6mvJoGFcM9BvE33fWAayrqkpojA,2116
766
766
  tools/test/test_sre_checkpoints.py,sha256=SKqPPTl9ua0RFdSSofnoQX-JZE6dFLO3LRhfQzqtfh8,2607
767
- qontract_reconcile-0.10.1rc727.dist-info/METADATA,sha256=lGusiFpOTOvJIK8nYP813fIHvezdgXL9ojNkgPvpgcU,2382
768
- qontract_reconcile-0.10.1rc727.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
769
- qontract_reconcile-0.10.1rc727.dist-info/entry_points.txt,sha256=rIxI5zWtHNlfpDeq1a7pZXAPoqf7HG32KMTN3MeWK_8,429
770
- qontract_reconcile-0.10.1rc727.dist-info/top_level.txt,sha256=l5ISPoXzt0SdR4jVdkfa7RPSKNc8zAHYWAnR-Dw8Ey8,24
771
- qontract_reconcile-0.10.1rc727.dist-info/RECORD,,
767
+ qontract_reconcile-0.10.1rc729.dist-info/METADATA,sha256=hDn3IRWhjYB1-GMrKs0vs1GtKi4bzpd-ZeUy_YB1MiE,2382
768
+ qontract_reconcile-0.10.1rc729.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
769
+ qontract_reconcile-0.10.1rc729.dist-info/entry_points.txt,sha256=rIxI5zWtHNlfpDeq1a7pZXAPoqf7HG32KMTN3MeWK_8,429
770
+ qontract_reconcile-0.10.1rc729.dist-info/top_level.txt,sha256=l5ISPoXzt0SdR4jVdkfa7RPSKNc8zAHYWAnR-Dw8Ey8,24
771
+ qontract_reconcile-0.10.1rc729.dist-info/RECORD,,
reconcile/cli.py CHANGED
@@ -23,6 +23,7 @@ from reconcile.status import (
23
23
  )
24
24
  from reconcile.utils import gql
25
25
  from reconcile.utils.aggregated_list import RunnerException
26
+ from reconcile.utils.amtool import AMTOOL_VERSION, AMTOOL_VERSION_REGEX
26
27
  from reconcile.utils.binary import (
27
28
  binary,
28
29
  binary_version,
@@ -30,6 +31,7 @@ from reconcile.utils.binary import (
30
31
  from reconcile.utils.exceptions import PrintToFileInGitRepositoryError
31
32
  from reconcile.utils.git import is_file_in_git_repo
32
33
  from reconcile.utils.gql import GqlApiSingleton
34
+ from reconcile.utils.promtool import PROMTOOL_VERSION, PROMTOOL_VERSION_REGEX
33
35
  from reconcile.utils.runtime.environment import init_env
34
36
  from reconcile.utils.runtime.integration import (
35
37
  ModuleArgsKwargsRunParams,
@@ -1278,6 +1280,7 @@ def aws_support_cases_sos(ctx, gitlab_project_id, thread_pool_size):
1278
1280
  @threaded()
1279
1281
  @binary(["oc", "ssh", "amtool"])
1280
1282
  @binary_version("oc", ["version", "--client"], OC_VERSION_REGEX, OC_VERSIONS)
1283
+ @binary_version("amtool", ["--version"], AMTOOL_VERSION_REGEX, AMTOOL_VERSION)
1281
1284
  @internal()
1282
1285
  @use_jump_host()
1283
1286
  @cluster_name
@@ -3010,6 +3013,7 @@ def dashdotdb_dora(ctx, gitlab_project_id, thread_pool_size):
3010
3013
  @integration.command(short_help="Tests prometheus rules using promtool.")
3011
3014
  @threaded(default=5)
3012
3015
  @binary(["promtool"])
3016
+ @binary_version("promtool", ["--version"], PROMTOOL_VERSION_REGEX, PROMTOOL_VERSION)
3013
3017
  @cluster_name
3014
3018
  @click.pass_context
3015
3019
  def prometheus_rules_tester(ctx, thread_pool_size, cluster_name):
@@ -292,7 +292,7 @@ def early_exit_desired_state(*args: Any, **kwargs: Any) -> dict[str, Any]:
292
292
 
293
293
  def desired_state_shard_config() -> DesiredStateShardConfig:
294
294
  return DesiredStateShardConfig(
295
- shard_arg_name="cluster_name",
295
+ shard_arg_name="cluster_names",
296
296
  shard_path_selectors={"state.*.shard"},
297
297
  sharded_run_review=lambda proposal: len(proposal.proposed_shards) <= 4,
298
298
  )
reconcile/utils/amtool.py CHANGED
@@ -7,6 +7,9 @@ from subprocess import (
7
7
  run,
8
8
  )
9
9
 
10
+ AMTOOL_VERSION = ["0.24.0"]
11
+ AMTOOL_VERSION_REGEX = r"^amtool,\sversion\s([\d]+\.[\d]+\.[\d]+).+$"
12
+
10
13
 
11
14
  class AmtoolResult:
12
15
  """This class represents a amtool command execution result"""
@@ -13,6 +13,9 @@ import yaml
13
13
  from reconcile.utils.defer import defer
14
14
  from reconcile.utils.structs import CommandExecutionResult
15
15
 
16
+ PROMTOOL_VERSION = ["2.33.3"]
17
+ PROMTOOL_VERSION_REGEX = r"^promtool,\sversion\s([\d]+\.[\d]+\.[\d]+).+$"
18
+
16
19
 
17
20
  def check_rule(yaml_spec: Mapping) -> CommandExecutionResult:
18
21
  """Run promtool check rules on the given yaml spec given as dict"""
tools/qontract_cli.py CHANGED
@@ -83,8 +83,13 @@ from reconcile.utils import (
83
83
  config,
84
84
  dnsutils,
85
85
  gql,
86
+ promtool,
86
87
  )
87
88
  from reconcile.utils.aws_api import AWSApi
89
+ from reconcile.utils.binary import (
90
+ binary,
91
+ binary_version,
92
+ )
88
93
  from reconcile.utils.early_exit_cache import (
89
94
  CacheKey,
90
95
  CacheKeyWithDigest,
@@ -3051,6 +3056,13 @@ def template(ctx, cluster, namespace, kind, name, path, secret_reader):
3051
3056
 
3052
3057
 
3053
3058
  @root.command()
3059
+ @binary(["promtool"])
3060
+ @binary_version(
3061
+ "promtool",
3062
+ ["--version"],
3063
+ promtool.PROMTOOL_VERSION_REGEX,
3064
+ promtool.PROMTOOL_VERSION,
3065
+ )
3054
3066
  @click.argument("path")
3055
3067
  @click.argument("cluster")
3056
3068
  @click.option(
@@ -3106,6 +3118,10 @@ def run_prometheus_test(ctx, path, cluster, namespace, secret_reader):
3106
3118
 
3107
3119
 
3108
3120
  @root.command()
3121
+ @binary(["amtool"])
3122
+ @binary_version(
3123
+ "amtool", ["--version"], amtool.AMTOOL_VERSION_REGEX, amtool.AMTOOL_VERSION
3124
+ )
3109
3125
  @click.argument("cluster")
3110
3126
  @click.argument("namespace")
3111
3127
  @click.argument("rules_path")