From 18fd758c732d294f7706ec6ee234ecb592175bd8 Mon Sep 17 00:00:00 2001 From: Yann Rouillard Date: Sat, 6 Apr 2024 01:38:20 +0200 Subject: [PATCH] fix: correct some error in new service name validation check --- kp_pre_commit_hooks/gitops-values-validation.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kp_pre_commit_hooks/gitops-values-validation.py b/kp_pre_commit_hooks/gitops-values-validation.py index 37b83f8..ca9e728 100755 --- a/kp_pre_commit_hooks/gitops-values-validation.py +++ b/kp_pre_commit_hooks/gitops-values-validation.py @@ -297,8 +297,8 @@ def validate_additional_checks(self, validator, additional_checks, value, schema yield from check_method(value, schema) def validate_service_name_matches_service_folder(self, value, schema): - if service_instance_config.path.name != value: - yield ValidationError(f"'{value}' does not match the service folder name '{service_instance_config.path.name}'") + if self.service_instance_config.path.name != value: + yield ValidationError(f"'{value}' does not match the service folder name '{self.service_instance_config.path.name}'") def validate_topic_name_compliance(self, value, schema): match = TOPIC_NAME_REGEXP.match(str(value))