From 0d5c4e4031dc223da6b9d5c995e3b47ca0ddd288 Mon Sep 17 00:00:00 2001 From: Frank Chen Date: Fri, 31 Jul 2026 00:50:38 +0800 Subject: [PATCH] fix: remove redundant Python assignments --- distribution/bin/jar-notice-lister.py | 6 +++--- examples/bin/start-druid-main.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/distribution/bin/jar-notice-lister.py b/distribution/bin/jar-notice-lister.py index 677da92bb314..1297fbf537f5 100755 --- a/distribution/bin/jar-notice-lister.py +++ b/distribution/bin/jar-notice-lister.py @@ -75,10 +75,10 @@ def get_notices(tmp_jar_path): for line in outstr.splitlines(): try: command = "jar xf {} {}".format(jar_file, line) - outstr = subprocess.check_output(command, shell=True).decode('UTF-8') + subprocess.check_output(command, shell=True) command = "mv {} {}.NOTICE-FILE".format(line, jar_file) - outstr = subprocess.check_output(command, shell=True).decode('UTF-8') + subprocess.check_output(command, shell=True) command = "cat {}.NOTICE-FILE".format(jar_file) outstr = subprocess.check_output(command, shell=True).decode('UTF-8') @@ -95,4 +95,4 @@ def get_notices(tmp_jar_path): try: main() except KeyboardInterrupt: - print('Interrupted, closing.') \ No newline at end of file + print('Interrupted, closing.') diff --git a/examples/bin/start-druid-main.py b/examples/bin/start-druid-main.py index f040f21c2f77..aebca7e365b9 100644 --- a/examples/bin/start-druid-main.py +++ b/examples/bin/start-druid-main.py @@ -529,7 +529,7 @@ def distribute_memory(services, total_memory): if service in MINIMUM_MEMORY_MB and allocated_memory < MINIMUM_MEMORY_MB.get(service): allocated_memory = MINIMUM_MEMORY_MB.get(service) - service_memory_config[service], allocated_memory = build_memory_config(service, allocated_memory) + service_memory_config[service] = build_memory_config(service, allocated_memory)[0] print_if_verbose('\nMemory distribution for services:') for key, value in service_memory_config.items():