From 91999edd8f0c63fe5950939c624cf29ffb2d4b14 Mon Sep 17 00:00:00 2001 From: Ruben Gonzalez Date: Wed, 3 Jun 2026 14:01:33 +0200 Subject: [PATCH] refactor: Use os.path.pathsep.join instead of string algebra --- fluster/main.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/fluster/main.py b/fluster/main.py index 3f23cd6f..4bb1e180 100644 --- a/fluster/main.py +++ b/fluster/main.py @@ -60,8 +60,12 @@ def __init__(self) -> None: # Prepend to the PATH the decoders_dir so that we can run them # without having to set the env for every single command - os.environ["PATH"] = ( - self.decoders_dir + os.path.pathsep + self.decoders_sys_dir + os.path.pathsep + os.environ["PATH"] + os.environ["PATH"] = os.path.pathsep.join( + [ + self.decoders_dir, + self.decoders_sys_dir, + os.environ.get("PATH", ""), + ] ) def run(self) -> None: