From cef0ec3a900af8b2caa32ab7712fffbd517d6a73 Mon Sep 17 00:00:00 2001 From: gaojiazhen Date: Thu, 21 Mar 2024 10:15:13 +0000 Subject: [PATCH] update src/oebuild/check_docker_tag.py. If you want to obtain all the keys in docker_config.tag_map, you don't need to assign a value through a dictionary to retrieve the key list. You can directly use docker_config. tag_map. keys() to obtain the key list of tag_map and assign it to self. tag_list. Signed-off-by: gaojiazhen --- src/oebuild/check_docker_tag.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/oebuild/check_docker_tag.py b/src/oebuild/check_docker_tag.py index 1080d16..f3f0f1c 100644 --- a/src/oebuild/check_docker_tag.py +++ b/src/oebuild/check_docker_tag.py @@ -39,10 +39,8 @@ class CheckDockerTag: oebuild_config = self.configure.parse_oebuild_config() docker_config = oebuild_config.docker tags = {} - for tag in docker_config.tag_map.values(): - tags[tag] = True - for key in tags: - self.tag_list.append(key) + self.tag_list = list(docker_config.tag_map.keys()) + def get_tags(self,): ''' -- Gitee