From 6e2a13d8a399bf497e54148556317852427c0798 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastjan=20Arti=C4=8D?= Date: Tue, 28 Apr 2026 16:15:20 +0000 Subject: [PATCH] Fix cross-device link error: use shutil.move instead of os.replace --- scripts/clip.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/clip.py b/scripts/clip.py index abf2b3f..e112dec 100644 --- a/scripts/clip.py +++ b/scripts/clip.py @@ -69,7 +69,7 @@ def run_clip(src, dst, start, duration, mode, lang, model, style, no_subs, quali # 2. Subtitles (opcijsko) if no_subs: - os.replace(reframed, dst) + shutil.move(str(reframed), str(dst)) else: cmd = [ "python3", str(SCRIPT_DIR / "subtitle.py"), @@ -82,7 +82,7 @@ def run_clip(src, dst, start, duration, mode, lang, model, style, no_subs, quali r = subprocess.run(cmd) if r.returncode != 0: print(f"❌ Subtitle napaka — shranim brez", file=sys.stderr) - os.replace(reframed, dst) + shutil.move(str(reframed), str(dst)) return True finally: import shutil